package org.mybatis.generator.api.plus;

import com.alibaba.fastjson.JSON;
import org.mybatis.generator.api.IntrospectedColumn;
import org.mybatis.generator.api.IntrospectedTable;

import java.io.*;
import java.util.*;

/**
 * @author wangfupeng
 */
public class MybatisUtilHtmlFront {

    public static void writeAllPage(IntrospectedTable introspectedTable, String htmlPath, String modelUrl, String fileUploadServer, String serverUrl, String basePackage, String aspectPackage) {

        writeCommonPageCommonJsJqueryJs(htmlPath, serverUrl);
        writeCommonPageCommonJsJqueryUiJs(htmlPath, serverUrl);
        writeCommonPageCommonCssJqueryUiCss(htmlPath, serverUrl);
        writeCommonPageCommonJsSha256Js(htmlPath, serverUrl);
        writeCommonPageCommonImageBlankImageAll(htmlPath, serverUrl);
        writeCommonPageCommonJsJjlcJs(htmlPath, serverUrl);

        writeCommonPageShareCssCommonCss(htmlPath, serverUrl);
        writeCommonPageShareJsCommonValueJs(htmlPath, serverUrl);
        writeCommonPageShareJsCommonFunctionJs(htmlPath, serverUrl, fileUploadServer);
        writeCommonPageShareJsCommonProvinceCityJs(htmlPath, serverUrl);
        writeCommonPageShareJsCommonTablesColumnsJs(htmlPath, serverUrl);

        writeCustomPageCustomJsCustomFunctionJs(htmlPath, serverUrl);
        writeCustomPageCustomJsCustomValueJs(htmlPath, serverUrl);

        writeTableJsCreatePage(introspectedTable, htmlPath, modelUrl, fileUploadServer, serverUrl, basePackage, aspectPackage);
        writeTableJsUpdatePage(introspectedTable, htmlPath, modelUrl, fileUploadServer, serverUrl, basePackage, aspectPackage);
        writeTableJsUpdatePreviewPage(introspectedTable, htmlPath, modelUrl, fileUploadServer, serverUrl, basePackage, aspectPackage);
        writeTableJsPreviewPage(introspectedTable, htmlPath, modelUrl, fileUploadServer, serverUrl, basePackage, aspectPackage);
        writeTableJsListPage(introspectedTable, htmlPath, modelUrl, fileUploadServer, serverUrl, basePackage, aspectPackage);
        writeTableJsListPreviewPage(introspectedTable, htmlPath, modelUrl, fileUploadServer, serverUrl, basePackage, aspectPackage);

        writeCustomPageCustomCssCustomCss(htmlPath, serverUrl, "");
        writeCustomPageCustomCssCustomCss(htmlPath, serverUrl, "-create");
        writeCustomPageCustomCssCustomCss(htmlPath, serverUrl, "-update");
        writeCustomPageCustomCssCustomCss(htmlPath, serverUrl, "-update-preview");
        writeCustomPageCustomCssCustomCss(htmlPath, serverUrl, "-preview");
        writeCustomPageCustomCssCustomCss(htmlPath, serverUrl, "-list");
        writeCustomPageCustomCssCustomCss(htmlPath, serverUrl, "-list-preview");

        writeTablePage(introspectedTable, htmlPath, modelUrl, fileUploadServer, serverUrl, basePackage, aspectPackage, "create", "创建");
        writeTablePage(introspectedTable, htmlPath, modelUrl, fileUploadServer, serverUrl, basePackage, aspectPackage, "update", "更改");
        writeTablePage(introspectedTable, htmlPath, modelUrl, fileUploadServer, serverUrl, basePackage, aspectPackage, "update-preview", "更改预览");
        writeTablePage(introspectedTable, htmlPath, modelUrl, fileUploadServer, serverUrl, basePackage, aspectPackage, "preview", "查看");
        writeTablePage(introspectedTable, htmlPath, modelUrl, fileUploadServer, serverUrl, basePackage, aspectPackage, "list", "列表");
        writeTablePage(introspectedTable, htmlPath, modelUrl, fileUploadServer, serverUrl, basePackage, aspectPackage, "list-preview", "查看列表");

        writeCssPage(introspectedTable, htmlPath, modelUrl, fileUploadServer, serverUrl, basePackage, aspectPackage, "create");
        writeCssPage(introspectedTable, htmlPath, modelUrl, fileUploadServer, serverUrl, basePackage, aspectPackage, "update");
        writeCssPage(introspectedTable, htmlPath, modelUrl, fileUploadServer, serverUrl, basePackage, aspectPackage, "update-preview");
        writeCssPage(introspectedTable, htmlPath, modelUrl, fileUploadServer, serverUrl, basePackage, aspectPackage, "preview");
        writeCssPage(introspectedTable, htmlPath, modelUrl, fileUploadServer, serverUrl, basePackage, aspectPackage, "list");
        writeCssPage(introspectedTable, htmlPath, modelUrl, fileUploadServer, serverUrl, basePackage, aspectPackage, "list-preview");

        writeCustomTableJsPage(introspectedTable, htmlPath, modelUrl, fileUploadServer, serverUrl, basePackage, aspectPackage, "create");
        writeCustomTableJsPage(introspectedTable, htmlPath, modelUrl, fileUploadServer, serverUrl, basePackage, aspectPackage, "update");
        writeCustomTableJsPage(introspectedTable, htmlPath, modelUrl, fileUploadServer, serverUrl, basePackage, aspectPackage, "update-preview");
        writeCustomTableJsPage(introspectedTable, htmlPath, modelUrl, fileUploadServer, serverUrl, basePackage, aspectPackage, "preview");
        writeCustomTableJsPage(introspectedTable, htmlPath, modelUrl, fileUploadServer, serverUrl, basePackage, aspectPackage, "list");
        writeCustomTableJsPage(introspectedTable, htmlPath, modelUrl, fileUploadServer, serverUrl, basePackage, aspectPackage, "list-preview");

        writeCustomTableCssPage(introspectedTable, htmlPath, modelUrl, fileUploadServer, serverUrl, basePackage, aspectPackage, "create");
        writeCustomTableCssPage(introspectedTable, htmlPath, modelUrl, fileUploadServer, serverUrl, basePackage, aspectPackage, "update");
        writeCustomTableCssPage(introspectedTable, htmlPath, modelUrl, fileUploadServer, serverUrl, basePackage, aspectPackage, "update-preview");
        writeCustomTableCssPage(introspectedTable, htmlPath, modelUrl, fileUploadServer, serverUrl, basePackage, aspectPackage, "preview");
        writeCustomTableCssPage(introspectedTable, htmlPath, modelUrl, fileUploadServer, serverUrl, basePackage, aspectPackage, "list");
        writeCustomTableCssPage(introspectedTable, htmlPath, modelUrl, fileUploadServer, serverUrl, basePackage, aspectPackage, "list-preview");
    }

    public static void write(String htmlPath, String serverUrl) {
        File file = null;
        OutputStream fileOutputStream = null;
        BufferedWriter bufferedWriter = null;
        try {
            File folder = new File(htmlPath + "/common/page-common/js/");
            folder.mkdirs();
            file = new File(htmlPath + "/common/page-common/js/jquery.js");
            //如果文件不存在，则创建文件，如果已存在，则覆盖
            file.createNewFile();
            fileOutputStream = new FileOutputStream(file);
            bufferedWriter = new BufferedWriter(new OutputStreamWriter(fileOutputStream, "utf-8"));
            bufferedWriter.write("");
            System.out.println("write to file success : " + file.getPath());
        } catch (IOException e) {
            e.printStackTrace();
        } finally {
            MybatisUtilCommon.closeBufferWriterAndFileOutputStream(fileOutputStream, bufferedWriter);
        }
    }

    public static void writePage(String htmlPath, String serverUrl) {
        File file = null;
        OutputStream fileOutputStream = null;
        BufferedWriter bufferedWriter = null;
        try {
            File folder = new File(htmlPath + "/common/page-custom/js/");
            folder.mkdirs();
            file = new File(htmlPath + "/common/page-custom/js/jquery.js");
            //如果文件不存在，则创建文件，如果已存在，则覆盖
            if (!file.exists()) {
                file.createNewFile();
                fileOutputStream = new FileOutputStream(file);
                bufferedWriter = new BufferedWriter(new OutputStreamWriter(fileOutputStream, "utf-8"));
                bufferedWriter.write("");
                System.out.println("write to file success : " + file.getPath());
            } else {
                System.out.println("write to file jump success : " + file.getPath());
            }
        } catch (IOException e) {
            e.printStackTrace();
        } finally {
            MybatisUtilCommon.closeBufferWriterAndFileOutputStream(fileOutputStream, bufferedWriter);
        }
    }

    public static void writeCommonPageCommonJsJqueryJs(String htmlPath, String serverUrl) {
        File file = null;
        OutputStream fileOutputStream = null;
        BufferedWriter bufferedWriter = null;
        try {
            File folder = new File(htmlPath + "/common/page-common/js/");
            folder.mkdirs();
            file = new File(htmlPath + "/common/page-common/js/jquery.js");
            //如果文件不存在，则创建文件，如果已存在，则覆盖
            file.createNewFile();
            fileOutputStream = new FileOutputStream(file);
            bufferedWriter = new BufferedWriter(new OutputStreamWriter(fileOutputStream, "utf-8"));
            bufferedWriter.write("window.jQuery||function(e,t){function n(e){var t=he[e]={};return K.each(e.split(te),function(e,n){t[n]=!0}),t}function r(e,n,r){if(r===t&&1===e.nodeType){var i=\"data-\"+n.replace(me,\"-$1\").toLowerCase();if(r=e.getAttribute(i),\"string\"==typeof r){try{r=\"true\"===r?!0:\"false\"===r?!1:\"null\"===r?null:+r+\"\"===r?+r:ge.test(r)?K.parseJSON(r):r}catch(o){}K.data(e,n,r)}else r=t}return r}function i(e){var t;for(t in e)if((\"data\"!==t||!K.isEmptyObject(e[t]))&&\"toJSON\"!==t)return!1;return!0}function o(){return!1}function a(){return!0}function s(e){return!e||!e.parentNode||11===e.parentNode.nodeType}function l(e,t){do e=e[t];while(e&&1!==e.nodeType);return e}function u(e,t,n){if(t=t||0,K.isFunction(t))return K.grep(e,function(e,r){var i=!!t.call(e,r,e);return i===n});if(t.nodeType)return K.grep(e,function(e,r){return e===t===n});if(\"string\"==typeof t){var r=K.grep(e,function(e){return 1===e.nodeType});if(qe.test(t))return K.filter(t,r,!n);t=K.filter(t,r)}return K.grep(e,function(e,r){return K.inArray(e,t)>=0===n})}function c(e){var t=We.split(\"|\"),n=e.createDocumentFragment();if(n.createElement)for(;t.length;)n.createElement(t.pop());return n}function f(e,t){return e.getElementsByTagName(t)[0]||e.appendChild(e.ownerDocument.createElement(t))}function p(e,t){if(1===t.nodeType&&K.hasData(e)){var n,r,i,o=K._data(e),a=K._data(t,o),s=o.events;if(s){delete a.handle,a.events={};for(n in s)for(r=0,i=s[n].length;i>r;r++)K.event.add(t,n,s[n][r])}a.data&&(a.data=K.extend({},a.data))}}function d(e,t){var n;1===t.nodeType&&(t.clearAttributes&&t.clearAttributes(),t.mergeAttributes&&t.mergeAttributes(e),n=t.nodeName.toLowerCase(),\"object\"===n?(t.parentNode&&(t.outerHTML=e.outerHTML),K.support.html5Clone&&e.innerHTML&&!K.trim(t.innerHTML)&&(t.innerHTML=e.innerHTML)):\"input\"===n&&Ve.test(e.type)?(t.defaultChecked=t.checked=e.checked,t.value!==e.value&&(t.value=e.value)):\"option\"===n?t.selected=e.defaultSelected:\"input\"===n||\"textarea\"===n?t.defaultValue=e.defaultValue:\"script\"===n&&t.text!==e.text&&(t.text=e.text),t.removeAttribute(K.expando))}function h(e){return\"undefined\"!=typeof e.getElementsByTagName?e.getElementsByTagName(\"*\"):\"undefined\"!=typeof e.querySelectorAll?e.querySelectorAll(\"*\"):[]}function g(e){Ve.test(e.type)&&(e.defaultChecked=e.checked)}function m(e,t){if(t in e)return t;for(var n=t.charAt(0).toUpperCase()+t.slice(1),r=t,i=yt.length;i--;)if(t=yt[i]+n,t in e)return t;return r}function y(e,t){return e=t||e,\"none\"===K.css(e,\"display\")||!K.contains(e.ownerDocument,e)}function v(e,t){for(var n,r,i=[],o=0,a=e.length;a>o;o++)n=e[o],n.style&&(i[o]=K._data(n,\"olddisplay\"),t?(!i[o]&&\"none\"===n.style.display&&(n.style.display=\"\"),\"\"===n.style.display&&y(n)&&(i[o]=K._data(n,\"olddisplay\",T(n.nodeName)))):(r=nt(n,\"display\"),!i[o]&&\"none\"!==r&&K._data(n,\"olddisplay\",r)));for(o=0;a>o;o++)n=e[o],n.style&&(t&&\"none\"!==n.style.display&&\"\"!==n.style.display||(n.style.display=t?i[o]||\"\":\"none\"));return e}function b(e,t,n){var r=ct.exec(t);return r?Math.max(0,r[1]-(n||0))+(r[2]||\"px\"):t}function x(e,t,n,r){for(var i=n===(r?\"border\":\"content\")?4:\"width\"===t?1:0,o=0;4>i;i+=2)\"margin\"===n&&(o+=K.css(e,n+mt[i],!0)),r?(\"content\"===n&&(o-=parseFloat(nt(e,\"padding\"+mt[i]))||0),\"margin\"!==n&&(o-=parseFloat(nt(e,\"border\"+mt[i]+\"Width\"))||0)):(o+=parseFloat(nt(e,\"padding\"+mt[i]))||0,\"padding\"!==n&&(o+=parseFloat(nt(e,\"border\"+mt[i]+\"Width\"))||0));return o}function w(e,t,n){var r=\"width\"===t?e.offsetWidth:e.offsetHeight,i=!0,o=K.support.boxSizing&&\"border-box\"===K.css(e,\"boxSizing\");if(0>=r||null==r){if(r=nt(e,t),(0>r||null==r)&&(r=e.style[t]),ft.test(r))return r;i=o&&(K.support.boxSizingReliable||r===e.style[t]),r=parseFloat(r)||0}return r+x(e,t,n||(o?\"border\":\"content\"),i)+\"px\"}function T(e){if(dt[e])return dt[e];var t=K(\"<\"+e+\">\").appendTo(R.body),n=t.css(\"display\");return t.remove(),(\"none\"===n||\"\"===n)&&(rt=R.body.appendChild(rt||K.extend(R.createElement(\"iframe\"),{frameBorder:0,width:0,height:0})),it&&rt.createElement||(it=(rt.contentWindow||rt.contentDocument).document,it.write(\"<!doctype html><html><body>\"),it.close()),t=it.body.appendChild(it.createElement(e)),n=nt(t,\"display\"),R.body.removeChild(rt)),dt[e]=n,n}function N(e,t,n,r){var i;if(K.isArray(t))K.each(t,function(t,i){n||xt.test(e)?r(e,i):N(e+\"[\"+(\"object\"==typeof i?t:\"\")+\"]\",i,n,r)});else if(n||\"object\"!==K.type(t))r(e,t);else for(i in t)N(e+\"[\"+i+\"]\",t[i],n,r)}function C(e){return function(t,n){\"string\"!=typeof t&&(n=t,t=\"*\");var r,i,o,a=t.toLowerCase().split(te),s=0,l=a.length;if(K.isFunction(n))for(;l>s;s++)r=a[s],o=/^\\+/.test(r),o&&(r=r.substr(1)||\"*\"),i=e[r]=e[r]||[],i[o?\"unshift\":\"push\"](n)}}function k(e,n,r,i,o,a){o=o||n.dataTypes[0],a=a||{},a[o]=!0;for(var s,l=e[o],u=0,c=l?l.length:0,f=e===qt;c>u&&(f||!s);u++)s=l[u](n,r,i),\"string\"==typeof s&&(!f||a[s]?s=t:(n.dataTypes.unshift(s),s=k(e,n,r,i,s,a)));return(f||!s)&&!a[\"*\"]&&(s=k(e,n,r,i,\"*\",a)),s}function E(e,n){var r,i,o=K.ajaxSettings.flatOptions||{};for(r in n)n[r]!==t&&((o[r]?e:i||(i={}))[r]=n[r]);i&&K.extend(!0,e,i)}function S(e,n,r){var i,o,a,s,l=e.contents,u=e.dataTypes,c=e.responseFields;for(o in c)o in r&&(n[c[o]]=r[o]);for(;\"*\"===u[0];)u.shift(),i===t&&(i=e.mimeType||n.getResponseHeader(\"content-type\"));if(i)for(o in l)if(l[o]&&l[o].test(i)){u.unshift(o);break}if(u[0]in r)a=u[0];else{for(o in r){if(!u[0]||e.converters[o+\" \"+u[0]]){a=o;break}s||(s=o)}a=a||s}return a?(a!==u[0]&&u.unshift(a),r[a]):void 0}function j(e,t){var n,r,i,o,a=e.dataTypes.slice(),s=a[0],l={},u=0;if(e.dataFilter&&(t=e.dataFilter(t,e.dataType)),a[1])for(n in e.converters)l[n.toLowerCase()]=e.converters[n];for(;i=a[++u];)if(\"*\"!==i){if(\"*\"!==s&&s!==i){if(n=l[s+\" \"+i]||l[\"* \"+i],!n)for(r in l)if(o=r.split(\" \"),o[1]===i&&(n=l[s+\" \"+o[0]]||l[\"* \"+o[0]])){n===!0?n=l[r]:l[r]!==!0&&(i=o[0],a.splice(u--,0,i));break}if(n!==!0)if(n&&e[\"throws\"])t=n(t);else try{t=n(t)}catch(c){return{state:\"parsererror\",error:n?c:\"No conversion from \"+s+\" to \"+i}}}s=i}return{state:\"success\",data:t}}function A(){try{return new e.XMLHttpRequest}catch(t){}}function L(){try{return new e.ActiveXObject(\"Microsoft.XMLHTTP\")}catch(t){}}function D(){return setTimeout(function(){Qt=t},0),Qt=K.now()}function H(e,t){K.each(t,function(t,n){for(var r=(Zt[t]||[]).concat(Zt[\"*\"]),i=0,o=r.length;o>i;i++)if(r[i].call(e,t,n))return})}function F(e,t,n){var r,i=0,o=Kt.length,a=K.Deferred().always(function(){delete s.elem}),s=function(){for(var t=Qt||D(),n=Math.max(0,l.startTime+l.duration-t),r=n/l.duration||0,i=1-r,o=0,s=l.tweens.length;s>o;o++)l.tweens[o].run(i);return a.notifyWith(e,[l,i,n]),1>i&&s?n:(a.resolveWith(e,[l]),!1)},l=a.promise({elem:e,props:K.extend({},t),opts:K.extend(!0,{specialEasing:{}},n),originalProperties:t,originalOptions:n,startTime:Qt||D(),duration:n.duration,tweens:[],createTween:function(t,n,r){var i=K.Tween(e,l.opts,t,n,l.opts.specialEasing[t]||l.opts.easing);return l.tweens.push(i),i},stop:function(t){for(var n=0,r=t?l.tweens.length:0;r>n;n++)l.tweens[n].run(1);return t?a.resolveWith(e,[l,t]):a.rejectWith(e,[l,t]),this}}),u=l.props;for(M(u,l.opts.specialEasing);o>i;i++)if(r=Kt[i].call(l,e,u,l.opts))return r;return H(l,u),K.isFunction(l.opts.start)&&l.opts.start.call(e,l),K.fx.timer(K.extend(s,{anim:l,queue:l.opts.queue,elem:e})),l.progress(l.opts.progress).done(l.opts.done,l.opts.complete).fail(l.opts.fail).always(l.opts.always)}function M(e,t){var n,r,i,o,a;for(n in e)if(r=K.camelCase(n),i=t[r],o=e[n],K.isArray(o)&&(i=o[1],o=e[n]=o[0]),n!==r&&(e[r]=o,delete e[n]),a=K.cssHooks[r],a&&\"expand\"in a){o=a.expand(o),delete e[r];for(n in o)n in e||(e[n]=o[n],t[n]=i)}else t[r]=i}function O(e,t,n){var r,i,o,a,s,l,u,c,f,p=this,d=e.style,h={},g=[],m=e.nodeType&&y(e);n.queue||(c=K._queueHooks(e,\"fx\"),null==c.unqueued&&(c.unqueued=0,f=c.empty.fire,c.empty.fire=function(){c.unqueued||f()}),c.unqueued++,p.always(function(){p.always(function(){c.unqueued--,K.queue(e,\"fx\").length||c.empty.fire()})})),1===e.nodeType&&(\"height\"in t||\"width\"in t)&&(n.overflow=[d.overflow,d.overflowX,d.overflowY],\"inline\"===K.css(e,\"display\")&&\"none\"===K.css(e,\"float\")&&(K.support.inlineBlockNeedsLayout&&\"inline\"!==T(e.nodeName)?d.zoom=1:d.display=\"inline-block\")),n.overflow&&(d.overflow=\"hidden\",K.support.shrinkWrapBlocks||p.done(function(){d.overflow=n.overflow[0],d.overflowX=n.overflow[1],d.overflowY=n.overflow[2]}));for(r in t)if(o=t[r],Vt.exec(o)){if(delete t[r],l=l||\"toggle\"===o,o===(m?\"hide\":\"show\"))continue;g.push(r)}if(a=g.length){s=K._data(e,\"fxshow\")||K._data(e,\"fxshow\",{}),\"hidden\"in s&&(m=s.hidden),l&&(s.hidden=!m),m?K(e).show():p.done(function(){K(e).hide()}),p.done(function(){var t;K.removeData(e,\"fxshow\",!0);for(t in h)K.style(e,t,h[t])});for(r=0;a>r;r++)i=g[r],u=p.createTween(i,m?s[i]:0),h[i]=s[i]||K.style(e,i),i in s||(s[i]=u.start,m&&(u.end=u.start,u.start=\"width\"===i||\"height\"===i?1:0))}}function q(e,t,n,r,i){return new q.prototype.init(e,t,n,r,i)}function _(e,t){var n,r={height:e},i=0;for(t=t?1:0;4>i;i+=2-t)n=mt[i],r[\"margin\"+n]=r[\"padding\"+n]=e;return t&&(r.opacity=r.width=e),r}function B(e){return K.isWindow(e)?e:9===e.nodeType?e.defaultView||e.parentWindow:!1}var W,P,R=e.document,$=e.location,I=e.navigator,z=e.jQuery,X=e.$,U=Array.prototype.push,Q=Array.prototype.slice,Y=Array.prototype.indexOf,V=Object.prototype.toString,J=Object.prototype.hasOwnProperty,G=String.prototype.trim,K=function(e,t){return new K.fn.init(e,t,W)},Z=/[\\-+]?(?:\\d*\\.|)\\d+(?:[eE][\\-+]?\\d+|)/.source,ee=/\\S/,te=/\\s+/,ne=/^[\\s\\uFEFF\\xA0]+|[\\s\\uFEFF\\xA0]+$/g,re=/^(?:[^#<]*(<[\\w\\W]+>)[^>]*$|#([\\w\\-]*)$)/,ie=/^<(\\w+)\\s*\\/?>(?:<\\/\\1>|)$/,oe=/^[\\],:{}\\s]*$/,ae=/(?:^|:|,)(?:\\s*\\[)+/g,se=/\\\\(?:[\"\\\\\\/bfnrt]|u[\\da-fA-F]{4})/g,le=/\"[^\"\\\\\\r\\n]*\"|true|false|null|-?(?:\\d\\d*\\.|)\\d+(?:[eE][\\-+]?\\d+|)/g,ue=/^-ms-/,ce=/-([\\da-z])/gi,fe=function(e,t){return(t+\"\").toUpperCase()},pe=function(){R.addEventListener?(R.removeEventListener(\"DOMContentLoaded\",pe,!1),K.ready()):\"complete\"===R.readyState&&(R.detachEvent(\"onreadystatechange\",pe),K.ready())},de={};K.fn=K.prototype={constructor:K,init:function(e,n,r){var i,o,a;if(!e)return this;if(e.nodeType)return this.context=this[0]=e,this.length=1,this;if(\"string\"==typeof e){if(i=\"<\"===e.charAt(0)&&\">\"===e.charAt(e.length-1)&&e.length>=3?[null,e,null]:re.exec(e),i&&(i[1]||!n)){if(i[1])return n=n instanceof K?n[0]:n,a=n&&n.nodeType?n.ownerDocument||n:R,e=K.parseHTML(i[1],a,!0),ie.test(i[1])&&K.isPlainObject(n)&&this.attr.call(e,n,!0),K.merge(this,e);if(o=R.getElementById(i[2]),o&&o.parentNode){if(o.id!==i[2])return r.find(e);this.length=1,this[0]=o}return this.context=R,this.selector=e,this}return!n||n.jquery?(n||r).find(e):this.constructor(n).find(e)}return K.isFunction(e)?r.ready(e):(e.selector!==t&&(this.selector=e.selector,this.context=e.context),K.makeArray(e,this))},selector:\"\",jquery:\"1.8.3\",length:0,size:function(){return this.length},toArray:function(){return Q.call(this)},get:function(e){return null==e?this.toArray():0>e?this[this.length+e]:this[e]},pushStack:function(e,t,n){var r=K.merge(this.constructor(),e);return r.prevObject=this,r.context=this.context,\"find\"===t?r.selector=this.selector+(this.selector?\" \":\"\")+n:t&&(r.selector=this.selector+\".\"+t+\"(\"+n+\")\"),r},each:function(e,t){return K.each(this,e,t)},ready:function(e){return K.ready.promise().done(e),this},eq:function(e){return e=+e,-1===e?this.slice(e):this.slice(e,e+1)},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},slice:function(){return this.pushStack(Q.apply(this,arguments),\"slice\",Q.call(arguments).join(\",\"))},map:function(e){return this.pushStack(K.map(this,function(t,n){return e.call(t,n,t)}))},end:function(){return this.prevObject||this.constructor(null)},push:U,sort:[].sort,splice:[].splice},K.fn.init.prototype=K.fn,K.extend=K.fn.extend=function(){var e,n,r,i,o,a,s=arguments[0]||{},l=1,u=arguments.length,c=!1;for(\"boolean\"==typeof s&&(c=s,s=arguments[1]||{},l=2),\"object\"!=typeof s&&!K.isFunction(s)&&(s={}),u===l&&(s=this,--l);u>l;l++)if(null!=(e=arguments[l]))for(n in e)r=s[n],i=e[n],s!==i&&(c&&i&&(K.isPlainObject(i)||(o=K.isArray(i)))?(o?(o=!1,a=r&&K.isArray(r)?r:[]):a=r&&K.isPlainObject(r)?r:{},s[n]=K.extend(c,a,i)):i!==t&&(s[n]=i));return s},K.extend({noConflict:function(t){return e.$===K&&(e.$=X),t&&e.jQuery===K&&(e.jQuery=z),K},isReady:!1,readyWait:1,holdReady:function(e){e?K.readyWait++:K.ready(!0)},ready:function(e){if(e===!0?!--K.readyWait:!K.isReady){if(!R.body)return setTimeout(K.ready,1);K.isReady=!0,e!==!0&&--K.readyWait>0||(P.resolveWith(R,[K]),K.fn.trigger&&K(R).trigger(\"ready\").off(\"ready\"))}},isFunction:function(e){return\"function\"===K.type(e)},isArray:Array.isArray||function(e){return\"array\"===K.type(e)},isWindow:function(e){return null!=e&&e==e.window},isNumeric:function(e){return!isNaN(parseFloat(e))&&isFinite(e)},type:function(e){return null==e?String(e):de[V.call(e)]||\"object\"},isPlainObject:function(e){if(!e||\"object\"!==K.type(e)||e.nodeType||K.isWindow(e))return!1;try{if(e.constructor&&!J.call(e,\"constructor\")&&!J.call(e.constructor.prototype,\"isPrototypeOf\"))return!1}catch(n){return!1}var r;for(r in e);return r===t||J.call(e,r)},isEmptyObject:function(e){var t;for(t in e)return!1;return!0},error:function(e){throw new Error(e)},parseHTML:function(e,t,n){var r;return e&&\"string\"==typeof e?(\"boolean\"==typeof t&&(n=t,t=0),t=t||R,(r=ie.exec(e))?[t.createElement(r[1])]:(r=K.buildFragment([e],t,n?null:[]),K.merge([],(r.cacheable?K.clone(r.fragment):r.fragment).childNodes))):null},parseJSON:function(t){return t&&\"string\"==typeof t?(t=K.trim(t),e.JSON&&e.JSON.parse?e.JSON.parse(t):oe.test(t.replace(se,\"@\").replace(le,\"]\").replace(ae,\"\"))?new Function(\"return \"+t)():void K.error(\"Invalid JSON: \"+t)):null},parseXML:function(n){var r,i;if(!n||\"string\"!=typeof n)return null;try{e.DOMParser?(i=new DOMParser,r=i.parseFromString(n,\"text/xml\")):(r=new ActiveXObject(\"Microsoft.XMLDOM\"),r.async=\"false\",r.loadXML(n))}catch(o){r=t}return(!r||!r.documentElement||r.getElementsByTagName(\"parsererror\").length)&&K.error(\"Invalid XML: \"+n),r},noop:function(){},globalEval:function(t){t&&ee.test(t)&&(e.execScript||function(t){e.eval.call(e,t)})(t)},camelCase:function(e){return e.replace(ue,\"ms-\").replace(ce,fe)},nodeName:function(e,t){return e.nodeName&&e.nodeName.toLowerCase()===t.toLowerCase()},each:function(e,n,r){var i,o=0,a=e.length,s=a===t||K.isFunction(e);if(r)if(s){for(i in e)if(n.apply(e[i],r)===!1)break}else for(;a>o&&n.apply(e[o++],r)!==!1;);else if(s){for(i in e)if(n.call(e[i],i,e[i])===!1)break}else for(;a>o&&n.call(e[o],o,e[o++])!==!1;);return e},trim:G&&!G.call(\"\\ufeff\\xa0\")?function(e){return null==e?\"\":G.call(e)}:function(e){return null==e?\"\":(e+\"\").replace(ne,\"\")},makeArray:function(e,t){var n,r=t||[];return null!=e&&(n=K.type(e),null==e.length||\"string\"===n||\"function\"===n||\"regexp\"===n||K.isWindow(e)?U.call(r,e):K.merge(r,e)),r},inArray:function(e,t,n){var r;if(t){if(Y)return Y.call(t,e,n);for(r=t.length,n=n?0>n?Math.max(0,r+n):n:0;r>n;n++)if(n in t&&t[n]===e)return n}return-1},merge:function(e,n){var r=n.length,i=e.length,o=0;if(\"number\"==typeof r)for(;r>o;o++)e[i++]=n[o];else for(;n[o]!==t;)e[i++]=n[o++];return e.length=i,e},grep:function(e,t,n){var r,i=[],o=0,a=e.length;for(n=!!n;a>o;o++)r=!!t(e[o],o),n!==r&&i.push(e[o]);return i},map:function(e,n,r){var i,o,a=[],s=0,l=e.length,u=e instanceof K||l!==t&&\"number\"==typeof l&&(l>0&&e[0]&&e[l-1]||0===l||K.isArray(e));if(u)for(;l>s;s++)i=n(e[s],s,r),null!=i&&(a[a.length]=i);else for(o in e)i=n(e[o],o,r),null!=i&&(a[a.length]=i);return a.concat.apply([],a)},guid:1,proxy:function(e,n){var r,i,o;return\"string\"==typeof n&&(r=e[n],n=e,e=r),K.isFunction(e)?(i=Q.call(arguments,2),o=function(){return e.apply(n,i.concat(Q.call(arguments)))},o.guid=e.guid=e.guid||K.guid++,o):t},access:function(e,n,r,i,o,a,s){var l,u=null==r,c=0,f=e.length;if(r&&\"object\"==typeof r){for(c in r)K.access(e,n,c,r[c],1,a,i);o=1}else if(i!==t){if(l=s===t&&K.isFunction(i),u&&(l?(l=n,n=function(e,t,n){return l.call(K(e),n)}):(n.call(e,i),n=null)),n)for(;f>c;c++)n(e[c],r,l?i.call(e[c],c,n(e[c],r)):i,s);o=1}return o?e:u?n.call(e):f?n(e[0],r):a},now:function(){return(new Date).getTime()}}),K.ready.promise=function(t){if(!P)if(P=K.Deferred(),\"complete\"===R.readyState)setTimeout(K.ready,1);else if(R.addEventListener)R.addEventListener(\"DOMContentLoaded\",pe,!1),e.addEventListener(\"load\",K.ready,!1);else{R.attachEvent(\"onreadystatechange\",pe),e.attachEvent(\"onload\",K.ready);var n=!1;try{n=null==e.frameElement&&R.documentElement}catch(r){}n&&n.doScroll&&function i(){if(!K.isReady){try{n.doScroll(\"left\")}catch(e){return setTimeout(i,50)}K.ready()}}()}return P.promise(t)},K.each(\"Boolean Number String Function Array Date RegExp Object\".split(\" \"),function(e,t){de[\"[object \"+t+\"]\"]=t.toLowerCase()}),W=K(R);var he={};K.Callbacks=function(e){e=\"string\"==typeof e?he[e]||n(e):K.extend({},e);var r,i,o,a,s,l,u=[],c=!e.once&&[],f=function(t){for(r=e.memory&&t,i=!0,l=a||0,a=0,s=u.length,o=!0;u&&s>l;l++)if(u[l].apply(t[0],t[1])===!1&&e.stopOnFalse){r=!1;break}o=!1,u&&(c?c.length&&f(c.shift()):r?u=[]:p.disable())},p={add:function(){if(u){var t=u.length;!function n(t){K.each(t,function(t,r){var i=K.type(r);\"function\"===i?(!e.unique||!p.has(r))&&u.push(r):r&&r.length&&\"string\"!==i&&n(r)})}(arguments),o?s=u.length:r&&(a=t,f(r))}return this},remove:function(){return u&&K.each(arguments,function(e,t){for(var n;(n=K.inArray(t,u,n))>-1;)u.splice(n,1),o&&(s>=n&&s--,l>=n&&l--)}),this},has:function(e){return K.inArray(e,u)>-1},empty:function(){return u=[],this},disable:function(){return u=c=r=t,this},disabled:function(){return!u},lock:function(){return c=t,r||p.disable(),this},locked:function(){return!c},fireWith:function(e,t){return t=t||[],t=[e,t.slice?t.slice():t],u&&(!i||c)&&(o?c.push(t):f(t)),this},fire:function(){return p.fireWith(this,arguments),this},fired:function(){return!!i}};return p},K.extend({Deferred:function(e){var t=[[\"resolve\",\"done\",K.Callbacks(\"once memory\"),\"resolved\"],[\"reject\",\"fail\",K.Callbacks(\"once memory\"),\"rejected\"],[\"notify\",\"progress\",K.Callbacks(\"memory\")]],n=\"pending\",r={state:function(){return n},always:function(){return i.done(arguments).fail(arguments),this},then:function(){var e=arguments;return K.Deferred(function(n){K.each(t,function(t,r){var o=r[0],a=e[t];i[r[1]](K.isFunction(a)?function(){var e=a.apply(this,arguments);e&&K.isFunction(e.promise)?e.promise().done(n.resolve).fail(n.reject).progress(n.notify):n[o+\"With\"](this===i?n:this,[e])}:n[o])}),e=null}).promise()},promise:function(e){return null!=e?K.extend(e,r):r}},i={};return r.pipe=r.then,K.each(t,function(e,o){var a=o[2],s=o[3];r[o[1]]=a.add,s&&a.add(function(){n=s},t[1^e][2].disable,t[2][2].lock),i[o[0]]=a.fire,i[o[0]+\"With\"]=a.fireWith}),r.promise(i),e&&e.call(i,i),i},when:function(e){var t,n,r,i=0,o=Q.call(arguments),a=o.length,s=1!==a||e&&K.isFunction(e.promise)?a:0,l=1===s?e:K.Deferred(),u=function(e,n,r){return function(i){n[e]=this,r[e]=arguments.length>1?Q.call(arguments):i,r===t?l.notifyWith(n,r):--s||l.resolveWith(n,r)}};if(a>1)for(t=new Array(a),n=new Array(a),r=new Array(a);a>i;i++)o[i]&&K.isFunction(o[i].promise)?o[i].promise().done(u(i,r,o)).fail(l.reject).progress(u(i,n,t)):--s;return s||l.resolveWith(r,o),l.promise()}}),K.support=function(){var t,n,r,i,o,a,s,l,u,c,f,p=R.createElement(\"div\");if(p.setAttribute(\"className\",\"t\"),p.innerHTML=\"  <link/><table></table><a href='/a'>a</a><input type='checkbox'/>\",n=p.getElementsByTagName(\"*\"),r=p.getElementsByTagName(\"a\")[0],!n||!r||!n.length)return{};i=R.createElement(\"select\"),o=i.appendChild(R.createElement(\"option\")),a=p.getElementsByTagName(\"input\")[0],r.style.cssText=\"top:1px;float:left;opacity:.5\",t={leadingWhitespace:3===p.firstChild.nodeType,tbody:!p.getElementsByTagName(\"tbody\").length,htmlSerialize:!!p.getElementsByTagName(\"link\").length,style:/top/.test(r.getAttribute(\"style\")),hrefNormalized:\"/a\"===r.getAttribute(\"href\"),opacity:/^0.5/.test(r.style.opacity),cssFloat:!!r.style.cssFloat,checkOn:\"on\"===a.value,optSelected:o.selected,getSetAttribute:\"t\"!==p.className,enctype:!!R.createElement(\"form\").enctype,html5Clone:\"<:nav></:nav>\"!==R.createElement(\"nav\").cloneNode(!0).outerHTML,boxModel:\"CSS1Compat\"===R.compatMode,submitBubbles:!0,changeBubbles:!0,focusinBubbles:!1,deleteExpando:!0,noCloneEvent:!0,inlineBlockNeedsLayout:!1,shrinkWrapBlocks:!1,reliableMarginRight:!0,boxSizingReliable:!0,pixelPosition:!1},a.checked=!0,t.noCloneChecked=a.cloneNode(!0).checked,i.disabled=!0,t.optDisabled=!o.disabled;try{delete p.test}catch(d){t.deleteExpando=!1}if(!p.addEventListener&&p.attachEvent&&p.fireEvent&&(p.attachEvent(\"onclick\",f=function(){t.noCloneEvent=!1}),p.cloneNode(!0).fireEvent(\"onclick\"),p.detachEvent(\"onclick\",f)),a=R.createElement(\"input\"),a.value=\"t\",a.setAttribute(\"type\",\"radio\"),t.radioValue=\"t\"===a.value,a.setAttribute(\"checked\",\"checked\"),a.setAttribute(\"name\",\"t\"),p.appendChild(a),s=R.createDocumentFragment(),s.appendChild(p.lastChild),t.checkClone=s.cloneNode(!0).cloneNode(!0).lastChild.checked,t.appendChecked=a.checked,s.removeChild(a),s.appendChild(p),p.attachEvent)for(u in{submit:!0,change:!0,focusin:!0})l=\"on\"+u,c=l in p,c||(p.setAttribute(l,\"return;\"),c=\"function\"==typeof p[l]),t[u+\"Bubbles\"]=c;return K(function(){var n,r,i,o,a=\"padding:0;margin:0;border:0;display:block;overflow:hidden;\",s=R.getElementsByTagName(\"body\")[0];s&&(n=R.createElement(\"div\"),n.style.cssText=\"visibility:hidden;border:0;width:0;height:0;position:static;top:0;margin-top:1px\",s.insertBefore(n,s.firstChild),r=R.createElement(\"div\"),n.appendChild(r),r.innerHTML=\"<table><tr><td></td><td>t</td></tr></table>\",i=r.getElementsByTagName(\"td\"),i[0].style.cssText=\"padding:0;margin:0;border:0;display:none\",c=0===i[0].offsetHeight,i[0].style.display=\"\",i[1].style.display=\"none\",t.reliableHiddenOffsets=c&&0===i[0].offsetHeight,r.innerHTML=\"\",r.style.cssText=\"box-sizing:border-box;-moz-box-sizing:border-box;-webkit-box-sizing:border-box;padding:1px;border:1px;display:block;width:4px;margin-top:1%;position:absolute;top:1%;\",t.boxSizing=4===r.offsetWidth,t.doesNotIncludeMarginInBodyOffset=1!==s.offsetTop,e.getComputedStyle&&(t.pixelPosition=\"1%\"!==(e.getComputedStyle(r,null)||{}).top,t.boxSizingReliable=\"4px\"===(e.getComputedStyle(r,null)||{width:\"4px\"}).width,o=R.createElement(\"div\"),o.style.cssText=r.style.cssText=a,o.style.marginRight=o.style.width=\"0\",r.style.width=\"1px\",r.appendChild(o),t.reliableMarginRight=!parseFloat((e.getComputedStyle(o,null)||{}).marginRight)),\"undefined\"!=typeof r.style.zoom&&(r.innerHTML=\"\",r.style.cssText=a+\"width:1px;padding:1px;display:inline;zoom:1\",t.inlineBlockNeedsLayout=3===r.offsetWidth,r.style.display=\"block\",r.style.overflow=\"visible\",r.innerHTML=\"<div></div>\",r.firstChild.style.width=\"5px\",t.shrinkWrapBlocks=3!==r.offsetWidth,n.style.zoom=1),s.removeChild(n),n=r=i=o=null)}),s.removeChild(p),n=r=i=o=a=s=p=null,t}();var ge=/(?:\\{[\\s\\S]*\\}|\\[[\\s\\S]*\\])$/,me=/([A-Z])/g;K.extend({cache:{},deletedIds:[],uuid:0,expando:\"jQuery\"+(K.fn.jquery+Math.random()).replace(/\\D/g,\"\"),noData:{embed:!0,object:\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\",applet:!0},hasData:function(e){return e=e.nodeType?K.cache[e[K.expando]]:e[K.expando],!!e&&!i(e)},data:function(e,n,r,i){if(K.acceptData(e)){var o,a,s=K.expando,l=\"string\"==typeof n,u=e.nodeType,c=u?K.cache:e,f=u?e[s]:e[s]&&s;if(f&&c[f]&&(i||c[f].data)||!l||r!==t)return f||(u?e[s]=f=K.deletedIds.pop()||K.guid++:f=s),c[f]||(c[f]={},u||(c[f].toJSON=K.noop)),(\"object\"==typeof n||\"function\"==typeof n)&&(i?c[f]=K.extend(c[f],n):c[f].data=K.extend(c[f].data,n)),o=c[f],i||(o.data||(o.data={}),o=o.data),r!==t&&(o[K.camelCase(n)]=r),l?(a=o[n],null==a&&(a=o[K.camelCase(n)])):a=o,a}},removeData:function(e,t,n){if(K.acceptData(e)){var r,o,a,s=e.nodeType,l=s?K.cache:e,u=s?e[K.expando]:K.expando;if(l[u]){if(t&&(r=n?l[u]:l[u].data)){K.isArray(t)||(t in r?t=[t]:(t=K.camelCase(t),t=t in r?[t]:t.split(\" \")));for(o=0,a=t.length;a>o;o++)delete r[t[o]];if(!(n?i:K.isEmptyObject)(r))return}(n||(delete l[u].data,i(l[u])))&&(s?K.cleanData([e],!0):K.support.deleteExpando||l!=l.window?delete l[u]:l[u]=null)}}},_data:function(e,t,n){return K.data(e,t,n,!0)},acceptData:function(e){var t=e.nodeName&&K.noData[e.nodeName.toLowerCase()];return!t||t!==!0&&e.getAttribute(\"classid\")===t}}),K.fn.extend({data:function(e,n){var i,o,a,s,l,u=this[0],c=0,f=null;if(e===t){if(this.length&&(f=K.data(u),1===u.nodeType&&!K._data(u,\"parsedAttrs\"))){for(a=u.attributes,l=a.length;l>c;c++)s=a[c].name,s.indexOf(\"data-\")||(s=K.camelCase(s.substring(5)),r(u,s,f[s]));K._data(u,\"parsedAttrs\",!0)}return f}return\"object\"==typeof e?this.each(function(){K.data(this,e)}):(i=e.split(\".\",2),i[1]=i[1]?\".\"+i[1]:\"\",o=i[1]+\"!\",K.access(this,function(n){return n===t?(f=this.triggerHandler(\"getData\"+o,[i[0]]),f===t&&u&&(f=K.data(u,e),f=r(u,e,f)),f===t&&i[1]?this.data(i[0]):f):(i[1]=n,void this.each(function(){var t=K(this);t.triggerHandler(\"setData\"+o,i),K.data(this,e,n),t.triggerHandler(\"changeData\"+o,i)}))},null,n,arguments.length>1,null,!1))},removeData:function(e){return this.each(function(){K.removeData(this,e)})}}),K.extend({queue:function(e,t,n){var r;return e?(t=(t||\"fx\")+\"queue\",r=K._data(e,t),n&&(!r||K.isArray(n)?r=K._data(e,t,K.makeArray(n)):r.push(n)),r||[]):void 0},dequeue:function(e,t){t=t||\"fx\";var n=K.queue(e,t),r=n.length,i=n.shift(),o=K._queueHooks(e,t),a=function(){K.dequeue(e,t)};\"inprogress\"===i&&(i=n.shift(),r--),i&&(\"fx\"===t&&n.unshift(\"inprogress\"),delete o.stop,i.call(e,a,o)),!r&&o&&o.empty.fire()},_queueHooks:function(e,t){var n=t+\"queueHooks\";return K._data(e,n)||K._data(e,n,{empty:K.Callbacks(\"once memory\").add(function(){K.removeData(e,t+\"queue\",!0),K.removeData(e,n,!0)})})}}),K.fn.extend({queue:function(e,n){var r=2;return\"string\"!=typeof e&&(n=e,e=\"fx\",r--),arguments.length<r?K.queue(this[0],e):n===t?this:this.each(function(){var t=K.queue(this,e,n);K._queueHooks(this,e),\"fx\"===e&&\"inprogress\"!==t[0]&&K.dequeue(this,e)})},dequeue:function(e){return this.each(function(){K.dequeue(this,e)})},delay:function(e,t){return e=K.fx?K.fx.speeds[e]||e:e,t=t||\"fx\",this.queue(t,function(t,n){var r=setTimeout(t,e);n.stop=function(){clearTimeout(r)}})},clearQueue:function(e){return this.queue(e||\"fx\",[])},promise:function(e,n){var r,i=1,o=K.Deferred(),a=this,s=this.length,l=function(){--i||o.resolveWith(a,[a])};for(\"string\"!=typeof e&&(n=e,e=t),e=e||\"fx\";s--;)r=K._data(a[s],e+\"queueHooks\"),r&&r.empty&&(i++,r.empty.add(l));return l(),o.promise(n)}});var ye,ve,be,xe=/[\\t\\r\\n]/g,we=/\\r/g,Te=/^(?:button|input)$/i,Ne=/^(?:button|input|object|select|textarea)$/i,Ce=/^a(?:rea|)$/i,ke=/^(?:autofocus|autoplay|async|checked|controls|defer|disabled|hidden|loop|multiple|open|readonly|required|scoped|selected)$/i,Ee=K.support.getSetAttribute;K.fn.extend({attr:function(e,t){return K.access(this,K.attr,e,t,arguments.length>1)},removeAttr:function(e){return this.each(function(){K.removeAttr(this,e)})},prop:function(e,t){return K.access(this,K.prop,e,t,arguments.length>1)},removeProp:function(e){return e=K.propFix[e]||e,this.each(function(){try{this[e]=t,delete this[e]}catch(n){}})},addClass:function(e){var t,n,r,i,o,a,s;if(K.isFunction(e))return this.each(function(t){K(this).addClass(e.call(this,t,this.className))});if(e&&\"string\"==typeof e)for(t=e.split(te),n=0,r=this.length;r>n;n++)if(i=this[n],1===i.nodeType)if(i.className||1!==t.length){for(o=\" \"+i.className+\" \",a=0,s=t.length;s>a;a++)o.indexOf(\" \"+t[a]+\" \")<0&&(o+=t[a]+\" \");i.className=K.trim(o)}else i.className=e;return this},removeClass:function(e){var n,r,i,o,a,s,l;if(K.isFunction(e))return this.each(function(t){K(this).removeClass(e.call(this,t,this.className))});if(e&&\"string\"==typeof e||e===t)for(n=(e||\"\").split(te),s=0,l=this.length;l>s;s++)if(i=this[s],1===i.nodeType&&i.className){for(r=(\" \"+i.className+\" \").replace(xe,\" \"),o=0,a=n.length;a>o;o++)for(;r.indexOf(\" \"+n[o]+\" \")>=0;)r=r.replace(\" \"+n[o]+\" \",\" \");i.className=e?K.trim(r):\"\"}return this},toggleClass:function(e,t){var n=typeof e,r=\"boolean\"==typeof t;return this.each(K.isFunction(e)?function(n){K(this).toggleClass(e.call(this,n,this.className,t),t)}:function(){if(\"string\"===n)for(var i,o=0,a=K(this),s=t,l=e.split(te);i=l[o++];)s=r?s:!a.hasClass(i),a[s?\"addClass\":\"removeClass\"](i);else(\"undefined\"===n||\"boolean\"===n)&&(this.className&&K._data(this,\"__className__\",this.className),this.className=this.className||e===!1?\"\":K._data(this,\"__className__\")||\"\")})},hasClass:function(e){for(var t=\" \"+e+\" \",n=0,r=this.length;r>n;n++)if(1===this[n].nodeType&&(\" \"+this[n].className+\" \").replace(xe,\" \").indexOf(t)>=0)return!0;return!1},val:function(e){var n,r,i,o=this[0];{if(arguments.length)return i=K.isFunction(e),this.each(function(r){var o,a=K(this);1===this.nodeType&&(o=i?e.call(this,r,a.val()):e,null==o?o=\"\":\"number\"==typeof o?o+=\"\":K.isArray(o)&&(o=K.map(o,function(e){return null==e?\"\":e+\"\"})),n=K.valHooks[this.type]||K.valHooks[this.nodeName.toLowerCase()],n&&\"set\"in n&&n.set(this,o,\"value\")!==t||(this.value=o))});if(o)return n=K.valHooks[o.type]||K.valHooks[o.nodeName.toLowerCase()],n&&\"get\"in n&&(r=n.get(o,\"value\"))!==t?r:(r=o.value,\"string\"==typeof r?r.replace(we,\"\"):null==r?\"\":r)}}}),K.extend({valHooks:{option:{get:function(e){var t=e.attributes.value;return!t||t.specified?e.value:e.text}},select:{get:function(e){for(var t,n,r=e.options,i=e.selectedIndex,o=\"select-one\"===e.type||0>i,a=o?null:[],s=o?i+1:r.length,l=0>i?s:o?i:0;s>l;l++)if(n=r[l],!(!n.selected&&l!==i||(K.support.optDisabled?n.disabled:null!==n.getAttribute(\"disabled\"))||n.parentNode.disabled&&K.nodeName(n.parentNode,\"optgroup\"))){if(t=K(n).val(),o)return t;a.push(t)}return a},set:function(e,t){var n=K.makeArray(t);return K(e).find(\"option\").each(function(){this.selected=K.inArray(K(this).val(),n)>=0}),n.length||(e.selectedIndex=-1),n}}},attrFn:{},attr:function(e,n,r,i){var o,a,s,l=e.nodeType;if(e&&3!==l&&8!==l&&2!==l)return i&&K.isFunction(K.fn[n])?K(e)[n](r):\"undefined\"==typeof e.getAttribute?K.prop(e,n,r):(s=1!==l||!K.isXMLDoc(e),s&&(n=n.toLowerCase(),a=K.attrHooks[n]||(ke.test(n)?ve:ye)),r!==t?null===r?void K.removeAttr(e,n):a&&\"set\"in a&&s&&(o=a.set(e,r,n))!==t?o:(e.setAttribute(n,r+\"\"),r):a&&\"get\"in a&&s&&null!==(o=a.get(e,n))?o:(o=e.getAttribute(n),null===o?t:o))},removeAttr:function(e,t){var n,r,i,o,a=0;if(t&&1===e.nodeType)for(r=t.split(te);a<r.length;a++)i=r[a],i&&(n=K.propFix[i]||i,o=ke.test(i),o||K.attr(e,i,\"\"),e.removeAttribute(Ee?i:n),o&&n in e&&(e[n]=!1))},attrHooks:{type:{set:function(e,t){if(Te.test(e.nodeName)&&e.parentNode)K.error(\"type property can't be changed\");else if(!K.support.radioValue&&\"radio\"===t&&K.nodeName(e,\"input\")){var n=e.value;return e.setAttribute(\"type\",t),n&&(e.value=n),t}}},value:{get:function(e,t){return ye&&K.nodeName(e,\"button\")?ye.get(e,t):t in e?e.value:null},set:function(e,t,n){return ye&&K.nodeName(e,\"button\")?ye.set(e,t,n):void(e.value=t)}}},propFix:{tabindex:\"tabIndex\",readonly:\"readOnly\",\"for\":\"htmlFor\",\"class\":\"className\",maxlength:\"maxLength\",cellspacing:\"cellSpacing\",cellpadding:\"cellPadding\",rowspan:\"rowSpan\",colspan:\"colSpan\",usemap:\"useMap\",frameborder:\"frameBorder\",contenteditable:\"contentEditable\"},prop:function(e,n,r){var i,o,a,s=e.nodeType;if(e&&3!==s&&8!==s&&2!==s)return a=1!==s||!K.isXMLDoc(e),a&&(n=K.propFix[n]||n,o=K.propHooks[n]),r!==t?o&&\"set\"in o&&(i=o.set(e,r,n))!==t?i:e[n]=r:o&&\"get\"in o&&null!==(i=o.get(e,n))?i:e[n]},propHooks:{tabIndex:{get:function(e){var n=e.getAttributeNode(\"tabindex\");return n&&n.specified?parseInt(n.value,10):Ne.test(e.nodeName)||Ce.test(e.nodeName)&&e.href?0:t}}}}),ve={get:function(e,n){var r,i=K.prop(e,n);return i===!0||\"boolean\"!=typeof i&&(r=e.getAttributeNode(n))&&r.nodeValue!==!1?n.toLowerCase():t},set:function(e,t,n){var r;return t===!1?K.removeAttr(e,n):(r=K.propFix[n]||n,r in e&&(e[r]=!0),e.setAttribute(n,n.toLowerCase())),n}},Ee||(be={name:!0,id:!0,coords:!0},ye=K.valHooks.button={get:function(e,n){var r;return r=e.getAttributeNode(n),r&&(be[n]?\"\"!==r.value:r.specified)?r.value:t},set:function(e,t,n){var r=e.getAttributeNode(n);return r||(r=R.createAttribute(n),e.setAttributeNode(r)),r.value=t+\"\"}},K.each([\"width\",\"height\"],function(e,t){K.attrHooks[t]=K.extend(K.attrHooks[t],{\n" +
                    "    set:function(e,n){return\"\"===n?(e.setAttribute(t,\"auto\"),n):void 0}})}),K.attrHooks.contenteditable={get:ye.get,set:function(e,t,n){\"\"===t&&(t=\"false\"),ye.set(e,t,n)}}),K.support.hrefNormalized||K.each([\"href\",\"src\",\"width\",\"height\"],function(e,n){K.attrHooks[n]=K.extend(K.attrHooks[n],{get:function(e){var r=e.getAttribute(n,2);return null===r?t:r}})}),K.support.style||(K.attrHooks.style={get:function(e){return e.style.cssText.toLowerCase()||t},set:function(e,t){return e.style.cssText=t+\"\"}}),K.support.optSelected||(K.propHooks.selected=K.extend(K.propHooks.selected,{get:function(e){var t=e.parentNode;return t&&(t.selectedIndex,t.parentNode&&t.parentNode.selectedIndex),null}})),K.support.enctype||(K.propFix.enctype=\"encoding\"),K.support.checkOn||K.each([\"radio\",\"checkbox\"],function(){K.valHooks[this]={get:function(e){return null===e.getAttribute(\"value\")?\"on\":e.value}}}),K.each([\"radio\",\"checkbox\"],function(){K.valHooks[this]=K.extend(K.valHooks[this],{set:function(e,t){return K.isArray(t)?e.checked=K.inArray(K(e).val(),t)>=0:void 0}})});var Se=/^(?:textarea|input|select)$/i,je=/^([^\\.]*|)(?:\\.(.+)|)$/,Ae=/(?:^|\\s)hover(\\.\\S+|)\\b/,Le=/^key/,De=/^(?:mouse|contextmenu)|click/,He=/^(?:focusinfocus|focusoutblur)$/,Fe=function(e){return K.event.special.hover?e:e.replace(Ae,\"mouseenter$1 mouseleave$1\")};K.event={add:function(e,n,r,i,o){var a,s,l,u,c,f,p,d,h,g,m;if(3!==e.nodeType&&8!==e.nodeType&&n&&r&&(a=K._data(e))){for(r.handler&&(h=r,r=h.handler,o=h.selector),r.guid||(r.guid=K.guid++),l=a.events,l||(a.events=l={}),s=a.handle,s||(a.handle=s=function(e){return\"undefined\"==typeof K||e&&K.event.triggered===e.type?t:K.event.dispatch.apply(s.elem,arguments)},s.elem=e),n=K.trim(Fe(n)).split(\" \"),u=0;u<n.length;u++)c=je.exec(n[u])||[],f=c[1],p=(c[2]||\"\").split(\".\").sort(),m=K.event.special[f]||{},f=(o?m.delegateType:m.bindType)||f,m=K.event.special[f]||{},d=K.extend({type:f,origType:c[1],data:i,handler:r,guid:r.guid,selector:o,needsContext:o&&K.expr.match.needsContext.test(o),namespace:p.join(\".\")},h),g=l[f],g||(g=l[f]=[],g.delegateCount=0,m.setup&&m.setup.call(e,i,p,s)!==!1||(e.addEventListener?e.addEventListener(f,s,!1):e.attachEvent&&e.attachEvent(\"on\"+f,s))),m.add&&(m.add.call(e,d),d.handler.guid||(d.handler.guid=r.guid)),o?g.splice(g.delegateCount++,0,d):g.push(d),K.event.global[f]=!0;e=null}},global:{},remove:function(e,t,n,r,i){var o,a,s,l,u,c,f,p,d,h,g,m=K.hasData(e)&&K._data(e);if(m&&(p=m.events)){for(t=K.trim(Fe(t||\"\")).split(\" \"),o=0;o<t.length;o++)if(a=je.exec(t[o])||[],s=l=a[1],u=a[2],s){for(d=K.event.special[s]||{},s=(r?d.delegateType:d.bindType)||s,h=p[s]||[],c=h.length,u=u?new RegExp(\"(^|\\\\.)\"+u.split(\".\").sort().join(\"\\\\.(?:.*\\\\.|)\")+\"(\\\\.|$)\"):null,f=0;f<h.length;f++)g=h[f],!(!i&&l!==g.origType||n&&n.guid!==g.guid||u&&!u.test(g.namespace)||r&&r!==g.selector&&(\"**\"!==r||!g.selector)||(h.splice(f--,1),g.selector&&h.delegateCount--,!d.remove||!d.remove.call(e,g)));0===h.length&&c!==h.length&&((!d.teardown||d.teardown.call(e,u,m.handle)===!1)&&K.removeEvent(e,s,m.handle),delete p[s])}else for(s in p)K.event.remove(e,s+t[o],n,r,!0);K.isEmptyObject(p)&&(delete m.handle,K.removeData(e,\"events\",!0))}},customEvent:{getData:!0,setData:!0,changeData:!0},trigger:function(n,r,i,o){if(!i||3!==i.nodeType&&8!==i.nodeType){var a,s,l,u,c,f,p,d,h,g,m=n.type||n,y=[];if(He.test(m+K.event.triggered))return;if(m.indexOf(\"!\")>=0&&(m=m.slice(0,-1),s=!0),m.indexOf(\".\")>=0&&(y=m.split(\".\"),m=y.shift(),y.sort()),(!i||K.event.customEvent[m])&&!K.event.global[m])return;if(n=\"object\"==typeof n?n[K.expando]?n:new K.Event(m,n):new K.Event(m),n.type=m,n.isTrigger=!0,n.exclusive=s,n.namespace=y.join(\".\"),n.namespace_re=n.namespace?new RegExp(\"(^|\\\\.)\"+y.join(\"\\\\.(?:.*\\\\.|)\")+\"(\\\\.|$)\"):null,f=m.indexOf(\":\")<0?\"on\"+m:\"\",!i){a=K.cache;for(l in a)a[l].events&&a[l].events[m]&&K.event.trigger(n,r,a[l].handle.elem,!0);return}if(n.result=t,n.target||(n.target=i),r=null!=r?K.makeArray(r):[],r.unshift(n),p=K.event.special[m]||{},p.trigger&&p.trigger.apply(i,r)===!1)return;if(h=[[i,p.bindType||m]],!o&&!p.noBubble&&!K.isWindow(i)){for(g=p.delegateType||m,u=He.test(g+m)?i:i.parentNode,c=i;u;u=u.parentNode)h.push([u,g]),c=u;c===(i.ownerDocument||R)&&h.push([c.defaultView||c.parentWindow||e,g])}for(l=0;l<h.length&&!n.isPropagationStopped();l++)u=h[l][0],n.type=h[l][1],d=(K._data(u,\"events\")||{})[n.type]&&K._data(u,\"handle\"),d&&d.apply(u,r),d=f&&u[f],d&&K.acceptData(u)&&d.apply&&d.apply(u,r)===!1&&n.preventDefault();return n.type=m,!(o||n.isDefaultPrevented()||p._default&&p._default.apply(i.ownerDocument,r)!==!1||\"click\"===m&&K.nodeName(i,\"a\")||!K.acceptData(i)||!f||!i[m]||(\"focus\"===m||\"blur\"===m)&&0===n.target.offsetWidth||K.isWindow(i)||(c=i[f],c&&(i[f]=null),K.event.triggered=m,i[m](),K.event.triggered=t,!c||!(i[f]=c))),n.result}},dispatch:function(n){n=K.event.fix(n||e.event);var r,i,o,a,s,l,u,c,f,p=(K._data(this,\"events\")||{})[n.type]||[],d=p.delegateCount,h=Q.call(arguments),g=!n.exclusive&&!n.namespace,m=K.event.special[n.type]||{},y=[];if(h[0]=n,n.delegateTarget=this,!m.preDispatch||m.preDispatch.call(this,n)!==!1){if(d&&(!n.button||\"click\"!==n.type))for(o=n.target;o!=this;o=o.parentNode||this)if(o.disabled!==!0||\"click\"!==n.type){for(s={},u=[],r=0;d>r;r++)c=p[r],f=c.selector,s[f]===t&&(s[f]=c.needsContext?K(f,this).index(o)>=0:K.find(f,this,null,[o]).length),s[f]&&u.push(c);u.length&&y.push({elem:o,matches:u})}for(p.length>d&&y.push({elem:this,matches:p.slice(d)}),r=0;r<y.length&&!n.isPropagationStopped();r++)for(l=y[r],n.currentTarget=l.elem,i=0;i<l.matches.length&&!n.isImmediatePropagationStopped();i++)c=l.matches[i],(g||!n.namespace&&!c.namespace||n.namespace_re&&n.namespace_re.test(c.namespace))&&(n.data=c.data,n.handleObj=c,a=((K.event.special[c.origType]||{}).handle||c.handler).apply(l.elem,h),a!==t&&(n.result=a,a===!1&&(n.preventDefault(),n.stopPropagation())));return m.postDispatch&&m.postDispatch.call(this,n),n.result}},props:\"attrChange attrName relatedNode srcElement altKey bubbles cancelable ctrlKey currentTarget eventPhase metaKey relatedTarget shiftKey target timeStamp view which\".split(\" \"),fixHooks:{},keyHooks:{props:\"char charCode key keyCode\".split(\" \"),filter:function(e,t){return null==e.which&&(e.which=null!=t.charCode?t.charCode:t.keyCode),e}},mouseHooks:{props:\"button buttons clientX clientY fromElement offsetX offsetY pageX pageY screenX screenY toElement\".split(\" \"),filter:function(e,n){var r,i,o,a=n.button,s=n.fromElement;return null==e.pageX&&null!=n.clientX&&(r=e.target.ownerDocument||R,i=r.documentElement,o=r.body,e.pageX=n.clientX+(i&&i.scrollLeft||o&&o.scrollLeft||0)-(i&&i.clientLeft||o&&o.clientLeft||0),e.pageY=n.clientY+(i&&i.scrollTop||o&&o.scrollTop||0)-(i&&i.clientTop||o&&o.clientTop||0)),!e.relatedTarget&&s&&(e.relatedTarget=s===e.target?n.toElement:s),!e.which&&a!==t&&(e.which=1&a?1:2&a?3:4&a?2:0),e}},fix:function(e){if(e[K.expando])return e;var t,n,r=e,i=K.event.fixHooks[e.type]||{},o=i.props?this.props.concat(i.props):this.props;for(e=K.Event(r),t=o.length;t;)n=o[--t],e[n]=r[n];return e.target||(e.target=r.srcElement||R),3===e.target.nodeType&&(e.target=e.target.parentNode),e.metaKey=!!e.metaKey,i.filter?i.filter(e,r):e},special:{load:{noBubble:!0},focus:{delegateType:\"focusin\"},blur:{delegateType:\"focusout\"},beforeunload:{setup:function(e,t,n){K.isWindow(this)&&(this.onbeforeunload=n)},teardown:function(e,t){this.onbeforeunload===t&&(this.onbeforeunload=null)}}},simulate:function(e,t,n,r){var i=K.extend(new K.Event,n,{type:e,isSimulated:!0,originalEvent:{}});r?K.event.trigger(i,null,t):K.event.dispatch.call(t,i),i.isDefaultPrevented()&&n.preventDefault()}},K.event.handle=K.event.dispatch,K.removeEvent=R.removeEventListener?function(e,t,n){e.removeEventListener&&e.removeEventListener(t,n,!1)}:function(e,t,n){var r=\"on\"+t;e.detachEvent&&(\"undefined\"==typeof e[r]&&(e[r]=null),e.detachEvent(r,n))},K.Event=function(e,t){return this instanceof K.Event?(e&&e.type?(this.originalEvent=e,this.type=e.type,this.isDefaultPrevented=e.defaultPrevented||e.returnValue===!1||e.getPreventDefault&&e.getPreventDefault()?a:o):this.type=e,t&&K.extend(this,t),this.timeStamp=e&&e.timeStamp||K.now(),this[K.expando]=!0,void 0):new K.Event(e,t)},K.Event.prototype={preventDefault:function(){this.isDefaultPrevented=a;var e=this.originalEvent;e&&(e.preventDefault?e.preventDefault():e.returnValue=!1)},stopPropagation:function(){this.isPropagationStopped=a;var e=this.originalEvent;e&&(e.stopPropagation&&e.stopPropagation(),e.cancelBubble=!0)},stopImmediatePropagation:function(){this.isImmediatePropagationStopped=a,this.stopPropagation()},isDefaultPrevented:o,isPropagationStopped:o,isImmediatePropagationStopped:o},K.each({mouseenter:\"mouseover\",mouseleave:\"mouseout\"},function(e,t){K.event.special[e]={delegateType:t,bindType:t,handle:function(e){{var n,r=this,i=e.relatedTarget,o=e.handleObj;o.selector}return(!i||i!==r&&!K.contains(r,i))&&(e.type=o.origType,n=o.handler.apply(this,arguments),e.type=t),n}}}),K.support.submitBubbles||(K.event.special.submit={setup:function(){return K.nodeName(this,\"form\")?!1:void K.event.add(this,\"click._submit keypress._submit\",function(e){var n=e.target,r=K.nodeName(n,\"input\")||K.nodeName(n,\"button\")?n.form:t;r&&!K._data(r,\"_submit_attached\")&&(K.event.add(r,\"submit._submit\",function(e){e._submit_bubble=!0}),K._data(r,\"_submit_attached\",!0))})},postDispatch:function(e){e._submit_bubble&&(delete e._submit_bubble,this.parentNode&&!e.isTrigger&&K.event.simulate(\"submit\",this.parentNode,e,!0))},teardown:function(){return K.nodeName(this,\"form\")?!1:void K.event.remove(this,\"._submit\")}}),K.support.changeBubbles||(K.event.special.change={setup:function(){return Se.test(this.nodeName)?((\"checkbox\"===this.type||\"radio\"===this.type)&&(K.event.add(this,\"propertychange._change\",function(e){\"checked\"===e.originalEvent.propertyName&&(this._just_changed=!0)}),K.event.add(this,\"click._change\",function(e){this._just_changed&&!e.isTrigger&&(this._just_changed=!1),K.event.simulate(\"change\",this,e,!0)})),!1):void K.event.add(this,\"beforeactivate._change\",function(e){var t=e.target;Se.test(t.nodeName)&&!K._data(t,\"_change_attached\")&&(K.event.add(t,\"change._change\",function(e){this.parentNode&&!e.isSimulated&&!e.isTrigger&&K.event.simulate(\"change\",this.parentNode,e,!0)}),K._data(t,\"_change_attached\",!0))})},handle:function(e){var t=e.target;return this!==t||e.isSimulated||e.isTrigger||\"radio\"!==t.type&&\"checkbox\"!==t.type?e.handleObj.handler.apply(this,arguments):void 0},teardown:function(){return K.event.remove(this,\"._change\"),!Se.test(this.nodeName)}}),K.support.focusinBubbles||K.each({focus:\"focusin\",blur:\"focusout\"},function(e,t){var n=0,r=function(e){K.event.simulate(t,e.target,K.event.fix(e),!0)};K.event.special[t]={setup:function(){0===n++&&R.addEventListener(e,r,!0)},teardown:function(){0===--n&&R.removeEventListener(e,r,!0)}}}),K.fn.extend({on:function(e,n,r,i,a){var s,l;if(\"object\"==typeof e){\"string\"!=typeof n&&(r=r||n,n=t);for(l in e)this.on(l,n,r,e[l],a);return this}if(null==r&&null==i?(i=n,r=n=t):null==i&&(\"string\"==typeof n?(i=r,r=t):(i=r,r=n,n=t)),i===!1)i=o;else if(!i)return this;return 1===a&&(s=i,i=function(e){return K().off(e),s.apply(this,arguments)},i.guid=s.guid||(s.guid=K.guid++)),this.each(function(){K.event.add(this,e,i,r,n)})},one:function(e,t,n,r){return this.on(e,t,n,r,1)},off:function(e,n,r){var i,a;if(e&&e.preventDefault&&e.handleObj)return i=e.handleObj,K(e.delegateTarget).off(i.namespace?i.origType+\".\"+i.namespace:i.origType,i.selector,i.handler),this;if(\"object\"==typeof e){for(a in e)this.off(a,n,e[a]);return this}return(n===!1||\"function\"==typeof n)&&(r=n,n=t),r===!1&&(r=o),this.each(function(){K.event.remove(this,e,r,n)})},bind:function(e,t,n){return this.on(e,null,t,n)},unbind:function(e,t){return this.off(e,null,t)},live:function(e,t,n){return K(this.context).on(e,this.selector,t,n),this},die:function(e,t){return K(this.context).off(e,this.selector||\"**\",t),this},delegate:function(e,t,n,r){return this.on(t,e,n,r)},undelegate:function(e,t,n){return 1===arguments.length?this.off(e,\"**\"):this.off(t,e||\"**\",n)},trigger:function(e,t){return this.each(function(){K.event.trigger(e,t,this)})},triggerHandler:function(e,t){return this[0]?K.event.trigger(e,t,this[0],!0):void 0},toggle:function(e){var t=arguments,n=e.guid||K.guid++,r=0,i=function(n){var i=(K._data(this,\"lastToggle\"+e.guid)||0)%r;return K._data(this,\"lastToggle\"+e.guid,i+1),n.preventDefault(),t[i].apply(this,arguments)||!1};for(i.guid=n;r<t.length;)t[r++].guid=n;return this.click(i)},hover:");
            bufferedWriter.write("function(e,t){return this.mouseenter(e).mouseleave(t||e)}}),K.each(\"blur focus focusin focusout load resize scroll unload click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup error contextmenu\".split(\" \"),function(e,t){K.fn[t]=function(e,n){return null==n&&(n=e,e=null),arguments.length>0?this.on(t,null,e,n):this.trigger(t)},Le.test(t)&&(K.event.fixHooks[t]=K.event.keyHooks),De.test(t)&&(K.event.fixHooks[t]=K.event.mouseHooks)}),function(e,t){function n(e,t,n,r){n=n||[],t=t||D;var i,o,a,s,l=t.nodeType;if(!e||\"string\"!=typeof e)return n;if(1!==l&&9!==l)return[];if(a=w(t),!a&&!r&&(i=ne.exec(e)))if(s=i[1]){if(9===l){if(o=t.getElementById(s),!o||!o.parentNode)return n;if(o.id===s)return n.push(o),n}else if(t.ownerDocument&&(o=t.ownerDocument.getElementById(s))&&T(t,o)&&o.id===s)return n.push(o),n}else{if(i[2])return q.apply(n,_.call(t.getElementsByTagName(e),0)),n;if((s=i[3])&&pe&&t.getElementsByClassName)return q.apply(n,_.call(t.getElementsByClassName(s),0)),n}return g(e.replace(G,\"$1\"),t,n,r,a)}function r(e){return function(t){var n=t.nodeName.toLowerCase();return\"input\"===n&&t.type===e}}function i(e){return function(t){var n=t.nodeName.toLowerCase();return(\"input\"===n||\"button\"===n)&&t.type===e}}function o(e){return W(function(t){return t=+t,W(function(n,r){for(var i,o=e([],n.length,t),a=o.length;a--;)n[i=o[a]]&&(n[i]=!(r[i]=n[i]))})})}function a(e,t,n){if(e===t)return n;for(var r=e.nextSibling;r;){if(r===t)return-1;r=r.nextSibling}return 1}function s(e,t){var r,i,o,a,s,l,u,c=$[A][e+\" \"];if(c)return t?0:c.slice(0);for(s=e,l=[],u=b.preFilter;s;){(!r||(i=Z.exec(s)))&&(i&&(s=s.slice(i[0].length)||s),l.push(o=[])),r=!1,(i=ee.exec(s))&&(o.push(r=new L(i.shift())),s=s.slice(r.length),r.type=i[0].replace(G,\" \"));for(a in b.filter)(i=se[a].exec(s))&&(!u[a]||(i=u[a](i)))&&(o.push(r=new L(i.shift())),s=s.slice(r.length),r.type=a,r.matches=i);if(!r)break}return t?s.length:s?n.error(e):$(e,l).slice(0)}function l(e,t,n){var r=t.dir,i=n&&\"parentNode\"===t.dir,o=M++;return t.first?function(t,n,o){for(;t=t[r];)if(i||1===t.nodeType)return e(t,n,o)}:function(t,n,a){if(a){for(;t=t[r];)if((i||1===t.nodeType)&&e(t,n,a))return t}else for(var s,l=F+\" \"+o+\" \",u=l+y;t=t[r];)if(i||1===t.nodeType){if((s=t[A])===u)return t.sizset;if(\"string\"==typeof s&&0===s.indexOf(l)){if(t.sizset)return t}else{if(t[A]=u,e(t,n,a))return t.sizset=!0,t;t.sizset=!1}}}}function u(e){return e.length>1?function(t,n,r){for(var i=e.length;i--;)if(!e[i](t,n,r))return!1;return!0}:e[0]}function c(e,t,n,r,i){for(var o,a=[],s=0,l=e.length,u=null!=t;l>s;s++)(o=e[s])&&(!n||n(o,r,i))&&(a.push(o),u&&t.push(s));return a}function f(e,t,n,r,i,o){return r&&!r[A]&&(r=f(r)),i&&!i[A]&&(i=f(i,o)),W(function(o,a,s,l){var u,f,p,d=[],g=[],m=a.length,y=o||h(t||\"*\",s.nodeType?[s]:s,[]),v=!e||!o&&t?y:c(y,d,e,s,l),b=n?i||(o?e:m||r)?[]:a:v;if(n&&n(v,b,s,l),r)for(u=c(b,g),r(u,[],s,l),f=u.length;f--;)(p=u[f])&&(b[g[f]]=!(v[g[f]]=p));if(o){if(i||e){if(i){for(u=[],f=b.length;f--;)(p=b[f])&&u.push(v[f]=p);i(null,b=[],u,l)}for(f=b.length;f--;)(p=b[f])&&(u=i?B.call(o,p):d[f])>-1&&(o[u]=!(a[u]=p))}}else b=c(b===a?b.splice(m,b.length):b),i?i(null,a,b,l):q.apply(a,b)})}function p(e){for(var t,n,r,i=e.length,o=b.relative[e[0].type],a=o||b.relative[\" \"],s=o?1:0,c=l(function(e){return e===t},a,!0),d=l(function(e){return B.call(t,e)>-1},a,!0),h=[function(e,n,r){return!o&&(r||n!==E)||((t=n).nodeType?c(e,n,r):d(e,n,r))}];i>s;s++)if(n=b.relative[e[s].type])h=[l(u(h),n)];else{if(n=b.filter[e[s].type].apply(null,e[s].matches),n[A]){for(r=++s;i>r&&!b.relative[e[r].type];r++);return f(s>1&&u(h),s>1&&e.slice(0,s-1).join(\"\").replace(G,\"$1\"),n,r>s&&p(e.slice(s,r)),i>r&&p(e=e.slice(r)),i>r&&e.join(\"\"))}h.push(n)}return u(h)}function d(e,t){var r=t.length>0,i=e.length>0,o=function(a,s,l,u,f){var p,d,h,g=[],m=0,v=\"0\",x=a&&[],w=null!=f,T=E,N=a||i&&b.find.TAG(\"*\",f&&s.parentNode||s),C=F+=null==T?1:Math.E;for(w&&(E=s!==D&&s,y=o.el);null!=(p=N[v]);v++){if(i&&p){for(d=0;h=e[d];d++)if(h(p,s,l)){u.push(p);break}w&&(F=C,y=++o.el)}r&&((p=!h&&p)&&m--,a&&x.push(p))}if(m+=v,r&&v!==m){for(d=0;h=t[d];d++)h(x,g,s,l);if(a){if(m>0)for(;v--;)!x[v]&&!g[v]&&(g[v]=O.call(u));g=c(g)}q.apply(u,g),w&&!a&&g.length>0&&m+t.length>1&&n.uniqueSort(u)}return w&&(F=C,E=T),x};return o.el=0,r?W(o):o}function h(e,t,r){for(var i=0,o=t.length;o>i;i++)n(e,t[i],r);return r}function g(e,t,n,r,i){{var o,a,l,u,c,f=s(e);f.length}if(!r&&1===f.length){if(a=f[0]=f[0].slice(0),a.length>2&&\"ID\"===(l=a[0]).type&&9===t.nodeType&&!i&&b.relative[a[1].type]){if(t=b.find.ID(l.matches[0].replace(ae,\"\"),t,i)[0],!t)return n;e=e.slice(a.shift().length)}for(o=se.POS.test(e)?-1:a.length-1;o>=0&&(l=a[o],!b.relative[u=l.type]);o--)if((c=b.find[u])&&(r=c(l.matches[0].replace(ae,\"\"),re.test(a[0].type)&&t.parentNode||t,i))){if(a.splice(o,1),e=r.length&&a.join(\"\"),!e)return q.apply(n,_.call(r,0)),n;break}}return N(e,f)(r,t,i,n,re.test(e)),n}function m(){}var y,v,b,x,w,T,N,C,k,E,S=!0,j=\"undefined\",A=(\"sizcache\"+Math.random()).replace(\".\",\"\"),L=String,D=e.document,H=D.documentElement,F=0,M=0,O=[].pop,q=[].push,_=[].slice,B=[].indexOf||function(e){for(var t=0,n=this.length;n>t;t++)if(this[t]===e)return t;return-1},W=function(e,t){return e[A]=null==t||t,e},P=function(){var e={},t=[];return W(function(n,r){return t.push(n)>b.cacheLength&&delete e[t.shift()],e[n+\" \"]=r},e)},R=P(),$=P(),I=P(),z=\"[\\\\x20\\\\t\\\\r\\\\n\\\\f]\",X=\"(?:\\\\\\\\.|[-\\\\w]|[^\\\\x00-\\\\xa0])+\",U=X.replace(\"w\",\"w#\"),Q=\"([*^$|!~]?=)\",Y=\"\\\\[\"+z+\"*(\"+X+\")\"+z+\"*(?:\"+Q+z+\"*(?:(['\\\"])((?:\\\\\\\\.|[^\\\\\\\\])*?)\\\\3|(\"+U+\")|)|)\"+z+\"*\\\\]\",V=\":(\"+X+\")(?:\\\\((?:(['\\\"])((?:\\\\\\\\.|[^\\\\\\\\])*?)\\\\2|([^()[\\\\]]*|(?:(?:\"+Y+\")|[^:]|\\\\\\\\.)*|.*))\\\\)|)\",J=\":(even|odd|eq|gt|lt|nth|first|last)(?:\\\\(\"+z+\"*((?:-\\\\d)?\\\\d*)\"+z+\"*\\\\)|)(?=[^-]|$)\",G=new RegExp(\"^\"+z+\"+|((?:^|[^\\\\\\\\])(?:\\\\\\\\.)*)\"+z+\"+$\",\"g\"),Z=new RegExp(\"^\"+z+\"*,\"+z+\"*\"),ee=new RegExp(\"^\"+z+\"*([\\\\x20\\\\t\\\\r\\\\n\\\\f>+~])\"+z+\"*\"),te=new RegExp(V),ne=/^(?:#([\\w\\-]+)|(\\w+)|\\.([\\w\\-]+))$/,re=/[\\x20\\t\\r\\n\\f]*[+~]/,ie=/h\\d/i,oe=/input|select|textarea|button/i,ae=/\\\\(?!\\\\)/g,se={ID:new RegExp(\"^#(\"+X+\")\"),CLASS:new RegExp(\"^\\\\.(\"+X+\")\"),NAME:new RegExp(\"^\\\\[name=['\\\"]?(\"+X+\")['\\\"]?\\\\]\"),TAG:new RegExp(\"^(\"+X.replace(\"w\",\"w*\")+\")\"),ATTR:new RegExp(\"^\"+Y),PSEUDO:new RegExp(\"^\"+V),POS:new RegExp(J,\"i\"),CHILD:new RegExp(\"^:(only|nth|first|last)-child(?:\\\\(\"+z+\"*(even|odd|(([+-]|)(\\\\d*)n|)\"+z+\"*(?:([+-]|)\"+z+\"*(\\\\d+)|))\"+z+\"*\\\\)|)\",\"i\"),needsContext:new RegExp(\"^\"+z+\"*[>+~]|\"+J,\"i\")},le=function(e){var t=D.createElement(\"div\");try{return e(t)}catch(n){return!1}finally{t=null}},ue=le(function(e){return e.appendChild(D.createComment(\"\")),!e.getElementsByTagName(\"*\").length}),ce=le(function(e){return e.innerHTML=\"<a href='#'></a>\",e.firstChild&&typeof e.firstChild.getAttribute!==j&&\"#\"===e.firstChild.getAttribute(\"href\")}),fe=le(function(e){e.innerHTML=\"<select></select>\";var t=typeof e.lastChild.getAttribute(\"multiple\");return\"boolean\"!==t&&\"string\"!==t}),pe=le(function(e){return e.innerHTML=\"<div class='hidden e'></div><div class='hidden'></div>\",e.getElementsByClassName&&e.getElementsByClassName(\"e\").length?(e.lastChild.className=\"e\",2===e.getElementsByClassName(\"e\").length):!1}),de=le(function(e){e.id=A+0,e.innerHTML=\"<a name='\"+A+\"'></a><div name='\"+A+\"'></div>\",H.insertBefore(e,H.firstChild);var t=D.getElementsByName&&D.getElementsByName(A).length===2+D.getElementsByName(A+0).length;return v=!D.getElementById(A),H.removeChild(e),t});try{_.call(H.childNodes,0)[0].nodeType}catch(he){_=function(e){for(var t,n=[];t=this[e];e++)n.push(t);return n}}n.matches=function(e,t){return n(e,null,null,t)},n.matchesSelector=function(e,t){return n(t,null,null,[e]).length>0},x=n.getText=function(e){var t,n=\"\",r=0,i=e.nodeType;if(i){if(1===i||9===i||11===i){if(\"string\"==typeof e.textContent)return e.textContent;for(e=e.firstChild;e;e=e.nextSibling)n+=x(e)}else if(3===i||4===i)return e.nodeValue}else for(;t=e[r];r++)n+=x(t);return n},w=n.isXML=function(e){var t=e&&(e.ownerDocument||e).documentElement;return t?\"HTML\"!==t.nodeName:!1},T=n.contains=H.contains?function(e,t){var n=9===e.nodeType?e.documentElement:e,r=t&&t.parentNode;return e===r||!!(r&&1===r.nodeType&&n.contains&&n.contains(r))}:H.compareDocumentPosition?function(e,t){return t&&!!(16&e.compareDocumentPosition(t))}:function(e,t){for(;t=t.parentNode;)if(t===e)return!0;return!1},n.attr=function(e,t){var n,r=w(e);return r||(t=t.toLowerCase()),(n=b.attrHandle[t])?n(e):r||fe?e.getAttribute(t):(n=e.getAttributeNode(t),n?\"boolean\"==typeof e[t]?e[t]?t:null:n.specified?n.value:null:null)},b=n.selectors={cacheLength:50,createPseudo:W,match:se,attrHandle:ce?{}:{href:function(e){return e.getAttribute(\"href\",2)},type:function(e){return e.getAttribute(\"type\")}},find:{ID:v?function(e,t,n){if(typeof t.getElementById!==j&&!n){var r=t.getElementById(e);return r&&r.parentNode?[r]:[]}}:function(e,n,r){if(typeof n.getElementById!==j&&!r){var i=n.getElementById(e);return i?i.id===e||typeof i.getAttributeNode!==j&&i.getAttributeNode(\"id\").value===e?[i]:t:[]}},TAG:ue?function(e,t){return typeof t.getElementsByTagName!==j?t.getElementsByTagName(e):void 0}:function(e,t){var n=t.getElementsByTagName(e);if(\"*\"===e){for(var r,i=[],o=0;r=n[o];o++)1===r.nodeType&&i.push(r);return i}return n},NAME:de&&function(e,t){return typeof t.getElementsByName!==j?t.getElementsByName(name):void 0},CLASS:pe&&function(e,t,n){return typeof t.getElementsByClassName===j||n?void 0:t.getElementsByClassName(e)}},relative:{\">\":{dir:\"parentNode\",first:!0},\" \":{dir:\"parentNode\"},\"+\":{dir:\"previousSibling\",first:!0},\"~\":{dir:\"previousSibling\"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(ae,\"\"),e[3]=(e[4]||e[5]||\"\").replace(ae,\"\"),\"~=\"===e[2]&&(e[3]=\" \"+e[3]+\" \"),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),\"nth\"===e[1]?(e[2]||n.error(e[0]),e[3]=+(e[3]?e[4]+(e[5]||1):2*(\"even\"===e[2]||\"odd\"===e[2])),e[4]=+(e[6]+e[7]||\"odd\"===e[2])):e[2]&&n.error(e[0]),e},PSEUDO:function(e){var t,n;return se.CHILD.test(e[0])?null:(e[3]?e[2]=e[3]:(t=e[4])&&(te.test(t)&&(n=s(t,!0))&&(n=t.indexOf(\")\",t.length-n)-t.length)&&(t=t.slice(0,n),e[0]=e[0].slice(0,n)),e[2]=t),e.slice(0,3))}},filter:{ID:v?function(e){return e=e.replace(ae,\"\"),function(t){return t.getAttribute(\"id\")===e}}:function(e){return e=e.replace(ae,\"\"),function(t){var n=typeof t.getAttributeNode!==j&&t.getAttributeNode(\"id\");return n&&n.value===e}},TAG:function(e){return\"*\"===e?function(){return!0}:(e=e.replace(ae,\"\").toLowerCase(),function(t){return t.nodeName&&t.nodeName.toLowerCase()===e})},CLASS:function(e){var t=R[A][e+\" \"];return t||(t=new RegExp(\"(^|\"+z+\")\"+e+\"(\"+z+\"|$)\"))&&R(e,function(e){return t.test(e.className||typeof e.getAttribute!==j&&e.getAttribute(\"class\")||\"\")})},ATTR:function(e,t,r){return function(i,o){var a=n.attr(i,e);return null==a?\"!=\"===t:t?(a+=\"\",\"=\"===t?a===r:\"!=\"===t?a!==r:\"^=\"===t?r&&0===a.indexOf(r):\"*=\"===t?r&&a.indexOf(r)>-1:\"$=\"===t?r&&a.substr(a.length-r.length)===r:\"~=\"===t?(\" \"+a+\" \").indexOf(r)>-1:\"|=\"===t?a===r||a.substr(0,r.length+1)===r+\"-\":!1):!0}},CHILD:function(e,t,n,r){return\"nth\"===e?function(e){var t,i,o=e.parentNode;if(1===n&&0===r)return!0;if(o)for(i=0,t=o.firstChild;t&&(1!==t.nodeType||(i++,e!==t));t=t.nextSibling);return i-=r,i===n||i%n===0&&i/n>=0}:function(t){var n=t;switch(e){case\"only\":case\"first\":for(;n=n.previousSibling;)if(1===n.nodeType)return!1;if(\"first\"===e)return!0;n=t;case\"last\":for(;n=n.nextSibling;)if(1===n.nodeType)return!1;return!0}}},PSEUDO:function(e,t){var r,i=b.pseudos[e]||b.setFilters[e.toLowerCase()]||n.error(\"unsupported pseudo: \"+e);return i[A]?i(t):i.length>1?(r=[e,e,\"\",t],b.setFilters.hasOwnProperty(e.toLowerCase())?W(function(e,n){for(var r,o=i(e,t),a=o.length;a--;)r=B.call(e,o[a]),e[r]=!(n[r]=o[a])}):function(e){return i(e,0,r)}):i}},pseudos:{not:W(function(e){var t=[],n=[],r=N(e.replace(G,\"$1\"));return r[A]?W(function(e,t,n,i){for(var o,a=r(e,null,i,[]),s=e.length;s--;)(o=a[s])&&(e[s]=!(t[s]=o))}):function(e,i,o){return t[0]=e,r(t,null,o,n),!n.pop()}}),has:W(function(e){return function(t){return n(e,t).length>0}}),contains:W(function(e){return function(t){return(t.textContent||t.innerText||x(t)).indexOf(e)>-1}}),enabled:function(e){return e.disabled===!1},disabled:function(e){return e.disabled===!0},checked:function(e){var t=e.nodeName.toLowerCase();return\"input\"===t&&!!e.checked||\"option\"===t&&!!e.selected},selected:function(e){return e.parentNode&&e.parentNode.selectedIndex,e.selected===!0},parent:function(e){return!b.pseudos.empty(e)},empty:function(e){var t;for(e=e.firstChild;e;){if(e.nodeName>\"@\"||3===(t=e.nodeType)||4===t)return!1;e=e.nextSibling}return!0},header:function(e){return ie.test(e.nodeName)},text:function(e){var t,n;return\"input\"===e.nodeName.toLowerCase()&&\"text\"===(t=e.type)&&(null==(n=e.getAttribute(\"type\"))||n.toLowerCase()===t)},radio:r(\"radio\"),checkbox:r(\"checkbox\"),file:r(\"file\"),password:r(\"password\"),image:r(\"image\"),submit:i(\"submit\"),reset:i(\"reset\"),button:function(e){var t=e.nodeName.toLowerCase();return\"input\"===t&&\"button\"===e.type||\"button\"===t},input:function(e){return oe.test(e.nodeName)},focus:function(e){var t=e.ownerDocument;return e===t.activeElement&&(!t.hasFocus||t.hasFocus())&&!!(e.type||e.href||~e.tabIndex)},active:function(e){return e===e.ownerDocument.activeElement},first:o(function(){return[0]}),last:o(function(e,t){return[t-1]}),eq:o(function(e,t,n){return[0>n?n+t:n]}),even:o(function(e,t){for(var n=0;t>n;n+=2)e.push(n);return e}),odd:o(function(e,t){for(var n=1;t>n;n+=2)e.push(n);return e}),lt:o(function(e,t,n){for(var r=0>n?n+t:n;--r>=0;)e.push(r);return e}),gt:o(function(e,t,n){for(var r=0>n?n+t:n;++r<t;)e.push(r);return e})}},C=H.compareDocumentPosition?function(e,t){return e===t?(k=!0,0):(e.compareDocumentPosition&&t.compareDocumentPosition?4&e.compareDocumentPosition(t):e.compareDocumentPosition)?-1:1}:function(e,t){if(e===t)return k=!0,0;if(e.sourceIndex&&t.sourceIndex)return e.sourceIndex-t.sourceIndex;var n,r,i=[],o=[],s=e.parentNode,l=t.parentNode,u=s;if(s===l)return a(e,t);if(!s)return-1;if(!l)return 1;for(;u;)i.unshift(u),u=u.parentNode;for(u=l;u;)o.unshift(u),u=u.parentNode;n=i.length,r=o.length;for(var c=0;n>c&&r>c;c++)if(i[c]!==o[c])return a(i[c],o[c]);return c===n?a(e,o[c],-1):a(i[c],t,1)},[0,0].sort(C),S=!k,n.uniqueSort=function(e){var t,n=[],r=1,i=0;if(k=S,e.sort(C),k){for(;t=e[r];r++)t===e[r-1]&&(i=n.push(r));for(;i--;)e.splice(n[i],1)}return e},n.error=function(e){throw new Error(\"Syntax error, unrecognized expression: \"+e)},N=n.compile=function(e,t){var n,r=[],i=[],o=I[A][e+\" \"];if(!o){for(t||(t=s(e)),n=t.length;n--;)o=p(t[n]),o[A]?r.push(o):i.push(o);o=I(e,d(i,r))}return o},D.querySelectorAll&&function(){var e,t=g,r=/'|\\\\/g,i=/\\=[\\x20\\t\\r\\n\\f]*([^'\"\\]]*)[\\x20\\t\\r\\n\\f]*\\]/g,o=[\":focus\"],a=[\":active\"],l=H.matchesSelector||H.mozMatchesSelector||H.webkitMatchesSelector||H.oMatchesSelector||H.msMatchesSelector;le(function(e){e.innerHTML=\"<select><option selected=''></option></select>\",e.querySelectorAll(\"[selected]\").length||o.push(\"\\\\[\"+z+\"*(?:checked|disabled|ismap|multiple|readonly|selected|value)\"),e.querySelectorAll(\":checked\").length||o.push(\":checked\")}),le(function(e){e.innerHTML=\"<p test=''></p>\",e.querySelectorAll(\"[test^='']\").length&&o.push(\"[*^$]=\"+z+\"*(?:\\\"\\\"|'')\"),e.innerHTML=\"<input type='hidden'/>\",e.querySelectorAll(\":enabled\").length||o.push(\":enabled\",\":disabled\")}),o=new RegExp(o.join(\"|\")),g=function(e,n,i,a,l){if(!a&&!l&&!o.test(e)){var u,c,f=!0,p=A,d=n,h=9===n.nodeType&&e;if(1===n.nodeType&&\"object\"!==n.nodeName.toLowerCase()){for(u=s(e),(f=n.getAttribute(\"id\"))?p=f.replace(r,\"\\\\$&\"):n.setAttribute(\"id\",p),p=\"[id='\"+p+\"'] \",c=u.length;c--;)u[c]=p+u[c].join(\"\");d=re.test(e)&&n.parentNode||n,h=u.join(\",\")}if(h)try{return q.apply(i,_.call(d.querySelectorAll(h),0)),i}catch(g){}finally{f||n.removeAttribute(\"id\")}}return t(e,n,i,a,l)},l&&(le(function(t){e=l.call(t,\"div\");try{l.call(t,\"[test!='']:sizzle\"),a.push(\"!=\",V)}catch(n){}}),a=new RegExp(a.join(\"|\")),n.matchesSelector=function(t,r){if(r=r.replace(i,\"='$1']\"),!w(t)&&!a.test(r)&&!o.test(r))try{var s=l.call(t,r);if(s||e||t.document&&11!==t.document.nodeType)return s}catch(u){}return n(r,null,null,[t]).length>0})}(),b.pseudos.nth=b.pseudos.eq,b.filters=m.prototype=b.pseudos,b.setFilters=new m,n.attr=K.attr,K.find=n,K.expr=n.selectors,K.expr[\":\"]=K.expr.pseudos,K.unique=n.uniqueSort,K.text=n.getText,K.isXMLDoc=n.isXML,K.contains=n.contains}(e);var Me=/Until$/,Oe=/^(?:parents|prev(?:Until|All))/,qe=/^.[^:#\\[\\.,]*$/,_e=K.expr.match.needsContext,Be={children:!0,contents:!0,next:!0,prev:!0};K.fn.extend({find:function(e){var t,n,r,i,o,a,s=this;if(\"string\"!=typeof e)return K(e).filter(function(){for(t=0,n=s.length;n>t;t++)if(K.contains(s[t],this))return!0});for(a=this.pushStack(\"\",\"find\",e),t=0,n=this.length;n>t;t++)if(r=a.length,K.find(e,this[t],a),t>0)for(i=r;i<a.length;i++)for(o=0;r>o;o++)if(a[o]===a[i]){a.splice(i--,1);break}return a},has:function(e){var t,n=K(e,this),r=n.length;return this.filter(function(){for(t=0;r>t;t++)if(K.contains(this,n[t]))return!0})},not:function(e){return this.pushStack(u(this,e,!1),\"not\",e)},filter:function(e){return this.pushStack(u(this,e,!0),\"filter\",e)},is:function(e){return!!e&&(\"string\"==typeof e?_e.test(e)?K(e,this.context).index(this[0])>=0:K.filter(e,this).length>0:this.filter(e).length>0)},closest:function(e,t){for(var n,r=0,i=this.length,o=[],a=_e.test(e)||\"string\"!=typeof e?K(e,t||this.context):0;i>r;r++)for(n=this[r];n&&n.ownerDocument&&n!==t&&11!==n.nodeType;){if(a?a.index(n)>-1:K.find.matchesSelector(n,e)){o.push(n);break}n=n.parentNode}return o=o.length>1?K.unique(o):o,this.pushStack(o,\"closest\",e)},index:function(e){return e?\"string\"==typeof e?K.inArray(this[0],K(e)):K.inArray(e.jquery?e[0]:e,this):this[0]&&this[0].parentNode?this.prevAll().length:-1},add:function(e,t){var n=\"string\"==typeof e?K(e,t):K.makeArray(e&&e.nodeType?[e]:e),r=K.merge(this.get(),n);return this.pushStack(s(n[0])||s(r[0])?r:K.unique(r))},addBack:function(e){return this.add(null==e?this.prevObject:this.prevObject.filter(e))}}),K.fn.andSelf=K.fn.addBack,K.each({parent:function(e){var t=e.parentNode;return t&&11!==t.nodeType?t:null},parents:function(e){return K.dir(e,\"parentNode\")},parentsUntil:function(e,t,n){return K.dir(e,\"parentNode\",n)},next:function(e){return l(e,\"nextSibling\")},prev:function(e){return l(e,\"previousSibling\")},nextAll:function(e){return K.dir(e,\"nextSibling\")},prevAll:function(e){return K.dir(e,\"previousSibling\")},nextUntil:function(e,t,n){return K.dir(e,\"nextSibling\",n)},prevUntil:function(e,t,n){return K.dir(e,\"previousSibling\",n)},siblings:function(e){return K.sibling((e.parentNode||{}).firstChild,e)},children:function(e){return K.sibling(e.firstChild)},contents:function(e){return K.nodeName(e,\"iframe\")?e.contentDocument||e.contentWindow.document:K.merge([],e.childNodes)}},function(e,t){K.fn[e]=function(n,r){var i=K.map(this,t,n);return Me.test(e)||(r=n),r&&\"string\"==typeof r&&(i=K.filter(r,i)),i=this.length>1&&!Be[e]?K.unique(i):i,this.length>1&&Oe.test(e)&&(i=i.reverse()),this.pushStack(i,e,Q.call(arguments).join(\",\"))}}),K.extend({filter:function(e,t,n){return n&&(e=\":not(\"+e+\")\"),1===t.length?K.find.matchesSelector(t[0],e)?[t[0]]:[]:K.find.matches(e,t)},dir:function(e,n,r){for(var i=[],o=e[n];o&&9!==o.nodeType&&(r===t||1!==o.nodeType||!K(o).is(r));)1===o.nodeType&&i.push(o),o=o[n];return i},sibling:function(e,t){for(var n=[];e;e=e.nextSibling)1===e.nodeType&&e!==t&&n.push(e);return n}});var We=\"abbr|article|aside|audio|bdi|canvas|data|datalist|details|figcaption|figure|footer|header|hgroup|mark|meter|nav|output|progress|section|summary|time|video\",Pe=/ jQuery\\d+=\"(?:null|\\d+)\"/g,Re=/^\\s+/,$e=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\\w:]+)[^>]*)\\/>/gi,Ie=/<([\\w:]+)/,ze=/<tbody/i,Xe=/<|&#?\\w+;/,Ue=/<(?:script|style|link)/i,Qe=/<(?:script|object|embed|option|style)/i,Ye=new RegExp(\"<(?:\"+We+\")[\\\\s/>]\",\"i\"),Ve=/^(?:checkbox|radio)$/,Je=/checked\\s*(?:[^=]|=\\s*.checked.)/i,Ge=/\\/(java|ecma)script/i,Ke=/^\\s*<!(?:\\[CDATA\\[|\\-\\-)|[\\]\\-]{2}>\\s*$/g,Ze={\n" +
                    "    option:[1,\"<select multiple='multiple'>\",\"</select>\"],legend:[1,\"<fieldset>\",\"</fieldset>\"],thead:[1,\"<table>\",\"</table>\"],tr:[2,\"<table><tbody>\",\"</tbody></table>\"],td:[3,\"<table><tbody><tr>\",\"</tr></tbody></table>\"],col:[2,\"<table><tbody></tbody><colgroup>\",\"</colgroup></table>\"],area:[1,\"<map>\",\"</map>\"],_default:[0,\"\",\"\"]},et=c(R),tt=et.appendChild(R.createElement(\"div\"));Ze.optgroup=Ze.option,Ze.tbody=Ze.tfoot=Ze.colgroup=Ze.caption=Ze.thead,Ze.th=Ze.td,K.support.htmlSerialize||(Ze._default=[1,\"X<div>\",\"</div>\"]),K.fn.extend({text:function(e){return K.access(this,function(e){return e===t?K.text(this):this.empty().append((this[0]&&this[0].ownerDocument||R).createTextNode(e))},null,e,arguments.length)},wrapAll:function(e){if(K.isFunction(e))return this.each(function(t){K(this).wrapAll(e.call(this,t))});if(this[0]){var t=K(e,this[0].ownerDocument).eq(0).clone(!0);this[0].parentNode&&t.insertBefore(this[0]),t.map(function(){for(var e=this;e.firstChild&&1===e.firstChild.nodeType;)e=e.firstChild;return e}).append(this)}return this},wrapInner:function(e){return this.each(K.isFunction(e)?function(t){K(this).wrapInner(e.call(this,t))}:function(){var t=K(this),n=t.contents();n.length?n.wrapAll(e):t.append(e)})},wrap:function(e){var t=K.isFunction(e);return this.each(function(n){K(this).wrapAll(t?e.call(this,n):e)})},unwrap:function(){return this.parent().each(function(){K.nodeName(this,\"body\")||K(this).replaceWith(this.childNodes)}).end()},append:function(){return this.domManip(arguments,!0,function(e){(1===this.nodeType||11===this.nodeType)&&this.appendChild(e)})},prepend:function(){return this.domManip(arguments,!0,function(e){(1===this.nodeType||11===this.nodeType)&&this.insertBefore(e,this.firstChild)})},before:function(){if(!s(this[0]))return this.domManip(arguments,!1,function(e){this.parentNode.insertBefore(e,this)});if(arguments.length){var e=K.clean(arguments);return this.pushStack(K.merge(e,this),\"before\",this.selector)}},after:function(){if(!s(this[0]))return this.domManip(arguments,!1,function(e){this.parentNode.insertBefore(e,this.nextSibling)});if(arguments.length){var e=K.clean(arguments);return this.pushStack(K.merge(this,e),\"after\",this.selector)}},remove:function(e,t){for(var n,r=0;null!=(n=this[r]);r++)(!e||K.filter(e,[n]).length)&&(!t&&1===n.nodeType&&(K.cleanData(n.getElementsByTagName(\"*\")),K.cleanData([n])),n.parentNode&&n.parentNode.removeChild(n));return this},empty:function(){for(var e,t=0;null!=(e=this[t]);t++)for(1===e.nodeType&&K.cleanData(e.getElementsByTagName(\"*\"));e.firstChild;)e.removeChild(e.firstChild);return this},clone:function(e,t){return e=null==e?!1:e,t=null==t?e:t,this.map(function(){return K.clone(this,e,t)})},html:function(e){return K.access(this,function(e){var n=this[0]||{},r=0,i=this.length;if(e===t)return 1===n.nodeType?n.innerHTML.replace(Pe,\"\"):t;if(!(\"string\"!=typeof e||Ue.test(e)||!K.support.htmlSerialize&&Ye.test(e)||!K.support.leadingWhitespace&&Re.test(e)||Ze[(Ie.exec(e)||[\"\",\"\"])[1].toLowerCase()])){e=e.replace($e,\"<$1></$2>\");try{for(;i>r;r++)n=this[r]||{},1===n.nodeType&&(K.cleanData(n.getElementsByTagName(\"*\")),n.innerHTML=e);n=0}catch(o){}}n&&this.empty().append(e)},null,e,arguments.length)},replaceWith:function(e){return s(this[0])?this.length?this.pushStack(K(K.isFunction(e)?e():e),\"replaceWith\",e):this:K.isFunction(e)?this.each(function(t){var n=K(this),r=n.html();n.replaceWith(e.call(this,t,r))}):(\"string\"!=typeof e&&(e=K(e).detach()),this.each(function(){var t=this.nextSibling,n=this.parentNode;K(this).remove(),t?K(t).before(e):K(n).append(e)}))},detach:function(e){return this.remove(e,!0)},domManip:function(e,n,r){e=[].concat.apply([],e);var i,o,a,s,l=0,u=e[0],c=[],p=this.length;if(!K.support.checkClone&&p>1&&\"string\"==typeof u&&Je.test(u))return this.each(function(){K(this).domManip(e,n,r)});if(K.isFunction(u))return this.each(function(i){var o=K(this);e[0]=u.call(this,i,n?o.html():t),o.domManip(e,n,r)});if(this[0]){if(i=K.buildFragment(e,this,c),a=i.fragment,o=a.firstChild,1===a.childNodes.length&&(a=o),o)for(n=n&&K.nodeName(o,\"tr\"),s=i.cacheable||p-1;p>l;l++)r.call(n&&K.nodeName(this[l],\"table\")?f(this[l],\"tbody\"):this[l],l===s?a:K.clone(a,!0,!0));a=o=null,c.length&&K.each(c,function(e,t){t.src?K.ajax?K.ajax({url:t.src,type:\"GET\",dataType:\"script\",async:!1,global:!1,\"throws\":!0}):K.error(\"no ajax\"):K.globalEval((t.text||t.textContent||t.innerHTML||\"\").replace(Ke,\"\")),t.parentNode&&t.parentNode.removeChild(t)})}return this}}),K.buildFragment=function(e,n,r){var i,o,a,s=e[0];return n=n||R,n=!n.nodeType&&n[0]||n,n=n.ownerDocument||n,1===e.length&&\"string\"==typeof s&&s.length<512&&n===R&&\"<\"===s.charAt(0)&&!Qe.test(s)&&(K.support.checkClone||!Je.test(s))&&(K.support.html5Clone||!Ye.test(s))&&(o=!0,i=K.fragments[s],a=i!==t),i||(i=n.createDocumentFragment(),K.clean(e,n,i,r),o&&(K.fragments[s]=a&&i)),{fragment:i,cacheable:o}},K.fragments={},K.each({appendTo:\"append\",prependTo:\"prepend\",insertBefore:\"before\",insertAfter:\"after\",replaceAll:\"replaceWith\"},function(e,t){K.fn[e]=function(n){var r,i=0,o=[],a=K(n),s=a.length,l=1===this.length&&this[0].parentNode;if((null==l||l&&11===l.nodeType&&1===l.childNodes.length)&&1===s)return a[t](this[0]),this;for(;s>i;i++)r=(i>0?this.clone(!0):this).get(),K(a[i])[t](r),o=o.concat(r);return this.pushStack(o,e,a.selector)}}),K.extend({clone:function(e,t,n){var r,i,o,a;if(K.support.html5Clone||K.isXMLDoc(e)||!Ye.test(\"<\"+e.nodeName+\">\")?a=e.cloneNode(!0):(tt.innerHTML=e.outerHTML,tt.removeChild(a=tt.firstChild)),!(K.support.noCloneEvent&&K.support.noCloneChecked||1!==e.nodeType&&11!==e.nodeType||K.isXMLDoc(e)))for(d(e,a),r=h(e),i=h(a),o=0;r[o];++o)i[o]&&d(r[o],i[o]);if(t&&(p(e,a),n))for(r=h(e),i=h(a),o=0;r[o];++o)p(r[o],i[o]);return r=i=null,a},clean:function(e,t,n,r){var i,o,a,s,l,u,f,p,d,h,m,y=t===R&&et,v=[];for(t&&\"undefined\"!=typeof t.createDocumentFragment||(t=R),i=0;null!=(a=e[i]);i++)if(\"number\"==typeof a&&(a+=\"\"),a){if(\"string\"==typeof a)if(Xe.test(a)){for(y=y||c(t),f=t.createElement(\"div\"),y.appendChild(f),a=a.replace($e,\"<$1></$2>\"),s=(Ie.exec(a)||[\"\",\"\"])[1].toLowerCase(),l=Ze[s]||Ze._default,u=l[0],f.innerHTML=l[1]+a+l[2];u--;)f=f.lastChild;if(!K.support.tbody)for(p=ze.test(a),d=\"table\"!==s||p?\"<table>\"!==l[1]||p?[]:f.childNodes:f.firstChild&&f.firstChild.childNodes,o=d.length-1;o>=0;--o)K.nodeName(d[o],\"tbody\")&&!d[o].childNodes.length&&d[o].parentNode.removeChild(d[o]);!K.support.leadingWhitespace&&Re.test(a)&&f.insertBefore(t.createTextNode(Re.exec(a)[0]),f.firstChild),a=f.childNodes,f.parentNode.removeChild(f)}else a=t.createTextNode(a);a.nodeType?v.push(a):K.merge(v,a)}if(f&&(a=f=y=null),!K.support.appendChecked)for(i=0;null!=(a=v[i]);i++)K.nodeName(a,\"input\")?g(a):\"undefined\"!=typeof a.getElementsByTagName&&K.grep(a.getElementsByTagName(\"input\"),g);if(n)for(h=function(e){return!e.type||Ge.test(e.type)?r?r.push(e.parentNode?e.parentNode.removeChild(e):e):n.appendChild(e):void 0},i=0;null!=(a=v[i]);i++)K.nodeName(a,\"script\")&&h(a)||(n.appendChild(a),\"undefined\"!=typeof a.getElementsByTagName&&(m=K.grep(K.merge([],a.getElementsByTagName(\"script\")),h),v.splice.apply(v,[i+1,0].concat(m)),i+=m.length));return v},cleanData:function(e,t){for(var n,r,i,o,a=0,s=K.expando,l=K.cache,u=K.support.deleteExpando,c=K.event.special;null!=(i=e[a]);a++)if((t||K.acceptData(i))&&(r=i[s],n=r&&l[r])){if(n.events)for(o in n.events)c[o]?K.event.remove(i,o):K.removeEvent(i,o,n.handle);l[r]&&(delete l[r],u?delete i[s]:i.removeAttribute?i.removeAttribute(s):i[s]=null,K.deletedIds.push(r))}}}),function(){var e,t;K.uaMatch=function(e){e=e.toLowerCase();var t=/(chrome)[ \\/]([\\w.]+)/.exec(e)||/(webkit)[ \\/]([\\w.]+)/.exec(e)||/(opera)(?:.*version|)[ \\/]([\\w.]+)/.exec(e)||/(msie) ([\\w.]+)/.exec(e)||e.indexOf(\"compatible\")<0&&/(mozilla)(?:.*? rv:([\\w.]+)|)/.exec(e)||[];return{browser:t[1]||\"\",version:t[2]||\"0\"}},e=K.uaMatch(I.userAgent),t={},e.browser&&(t[e.browser]=!0,t.version=e.version),t.chrome?t.webkit=!0:t.webkit&&(t.safari=!0),K.browser=t,K.sub=function(){function e(t,n){return new e.fn.init(t,n)}K.extend(!0,e,this),e.superclass=this,e.fn=e.prototype=this(),e.fn.constructor=e,e.sub=this.sub,e.fn.init=function(n,r){return r&&r instanceof K&&!(r instanceof e)&&(r=e(r)),K.fn.init.call(this,n,r,t)},e.fn.init.prototype=e.fn;var t=e(R);return e}}();var nt,rt,it,ot=/alpha\\([^)]*\\)/i,at=/opacity=([^)]*)/,st=/^(top|right|bottom|left)$/,lt=/^(none|table(?!-c[ea]).+)/,ut=/^margin/,ct=new RegExp(\"^(\"+Z+\")(.*)$\",\"i\"),ft=new RegExp(\"^(\"+Z+\")(?!px)[a-z%]+$\",\"i\"),pt=new RegExp(\"^([-+])=(\"+Z+\")\",\"i\"),dt={BODY:\"block\"},ht={position:\"absolute\",visibility:\"hidden\",display:\"block\"},gt={letterSpacing:0,fontWeight:400},mt=[\"Top\",\"Right\",\"Bottom\",\"Left\"],yt=[\"Webkit\",\"O\",\"Moz\",\"ms\"],vt=K.fn.toggle;K.fn.extend({css:function(e,n){return K.access(this,function(e,n,r){return r!==t?K.style(e,n,r):K.css(e,n)},e,n,arguments.length>1)},show:function(){return v(this,!0)},hide:function(){return v(this)},toggle:function(e,t){var n=\"boolean\"==typeof e;return K.isFunction(e)&&K.isFunction(t)?vt.apply(this,arguments):this.each(function(){(n?e:y(this))?K(this).show():K(this).hide()})}}),K.extend({cssHooks:{opacity:{get:function(e,t){if(t){var n=nt(e,\"opacity\");return\"\"===n?\"1\":n}}}},cssNumber:{fillOpacity:!0,fontWeight:!0,lineHeight:!0,opacity:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{\"float\":K.support.cssFloat?\"cssFloat\":\"styleFloat\"},style:function(e,n,r,i){if(e&&3!==e.nodeType&&8!==e.nodeType&&e.style){var o,a,s,l=K.camelCase(n),u=e.style;if(n=K.cssProps[l]||(K.cssProps[l]=m(u,l)),s=K.cssHooks[n]||K.cssHooks[l],r===t)return s&&\"get\"in s&&(o=s.get(e,!1,i))!==t?o:u[n];if(a=typeof r,\"string\"===a&&(o=pt.exec(r))&&(r=(o[1]+1)*o[2]+parseFloat(K.css(e,n)),a=\"number\"),!(null==r||\"number\"===a&&isNaN(r)||(\"number\"===a&&!K.cssNumber[l]&&(r+=\"px\"),s&&\"set\"in s&&(r=s.set(e,r,i))===t)))try{u[n]=r}catch(c){}}},css:function(e,n,r,i){var o,a,s,l=K.camelCase(n);return n=K.cssProps[l]||(K.cssProps[l]=m(e.style,l)),s=K.cssHooks[n]||K.cssHooks[l],s&&\"get\"in s&&(o=s.get(e,!0,i)),o===t&&(o=nt(e,n)),\"normal\"===o&&n in gt&&(o=gt[n]),r||i!==t?(a=parseFloat(o),r||K.isNumeric(a)?a||0:o):o},swap:function(e,t,n){var r,i,o={};for(i in t)o[i]=e.style[i],e.style[i]=t[i];r=n.call(e);for(i in t)e.style[i]=o[i];return r}}),e.getComputedStyle?nt=function(t,n){var r,i,o,a,s=e.getComputedStyle(t,null),l=t.style;return s&&(r=s.getPropertyValue(n)||s[n],\"\"===r&&!K.contains(t.ownerDocument,t)&&(r=K.style(t,n)),ft.test(r)&&ut.test(n)&&(i=l.width,o=l.minWidth,a=l.maxWidth,l.minWidth=l.maxWidth=l.width=r,r=s.width,l.width=i,l.minWidth=o,l.maxWidth=a)),r}:R.documentElement.currentStyle&&(nt=function(e,t){var n,r,i=e.currentStyle&&e.currentStyle[t],o=e.style;return null==i&&o&&o[t]&&(i=o[t]),ft.test(i)&&!st.test(t)&&(n=o.left,r=e.runtimeStyle&&e.runtimeStyle.left,r&&(e.runtimeStyle.left=e.currentStyle.left),o.left=\"fontSize\"===t?\"1em\":i,i=o.pixelLeft+\"px\",o.left=n,r&&(e.runtimeStyle.left=r)),\"\"===i?\"auto\":i}),K.each([\"height\",\"width\"],function(e,t){K.cssHooks[t]={get:function(e,n,r){return n?0===e.offsetWidth&&lt.test(nt(e,\"display\"))?K.swap(e,ht,function(){return w(e,t,r)}):w(e,t,r):void 0},set:function(e,n,r){return b(e,n,r?x(e,t,r,K.support.boxSizing&&\"border-box\"===K.css(e,\"boxSizing\")):0)}}}),K.support.opacity||(K.cssHooks.opacity={get:function(e,t){return at.test((t&&e.currentStyle?e.currentStyle.filter:e.style.filter)||\"\")?.01*parseFloat(RegExp.$1)+\"\":t?\"1\":\"\"},set:function(e,t){var n=e.style,r=e.currentStyle,i=K.isNumeric(t)?\"alpha(opacity=\"+100*t+\")\":\"\",o=r&&r.filter||n.filter||\"\";n.zoom=1,t>=1&&\"\"===K.trim(o.replace(ot,\"\"))&&n.removeAttribute&&(n.removeAttribute(\"filter\"),r&&!r.filter)||(n.filter=ot.test(o)?o.replace(ot,i):o+\" \"+i)}}),K(function(){K.support.reliableMarginRight||(K.cssHooks.marginRight={get:function(e,t){return K.swap(e,{display:\"inline-block\"},function(){return t?nt(e,\"marginRight\"):void 0})}}),!K.support.pixelPosition&&K.fn.position&&K.each([\"top\",\"left\"],function(e,t){K.cssHooks[t]={get:function(e,n){if(n){var r=nt(e,t);return ft.test(r)?K(e).position()[t]+\"px\":r}}}})}),K.expr&&K.expr.filters&&(K.expr.filters.hidden=function(e){return 0===e.offsetWidth&&0===e.offsetHeight||!K.support.reliableHiddenOffsets&&\"none\"===(e.style&&e.style.display||nt(e,\"display\"))},K.expr.filters.visible=function(e){return!K.expr.filters.hidden(e)}),K.each({margin:\"\",padding:\"\",border:\"Width\"},function(e,t){K.cssHooks[e+t]={expand:function(n){var r,i=\"string\"==typeof n?n.split(\" \"):[n],o={};for(r=0;4>r;r++)o[e+mt[r]+t]=i[r]||i[r-2]||i[0];return o}},ut.test(e)||(K.cssHooks[e+t].set=b)});var bt=/%20/g,xt=/\\[\\]$/,wt=/\\r?\\n/g,Tt=/^(?:color|date|datetime|datetime-local|email|hidden|month|number|password|range|search|tel|text|time|url|week)$/i,Nt=/^(?:select|textarea)/i;K.fn.extend({serialize:function(){return K.param(this.serializeArray())},serializeArray:function(){return this.map(function(){return this.elements?K.makeArray(this.elements):this}).filter(function(){return this.name&&!this.disabled&&(this.checked||Nt.test(this.nodeName)||Tt.test(this.type))}).map(function(e,t){var n=K(this).val();return null==n?null:K.isArray(n)?K.map(n,function(e,n){return{name:t.name,value:e.replace(wt,\"\\r\\n\")}}):{name:t.name,value:n.replace(wt,\"\\r\\n\")}}).get()}}),K.param=function(e,n){var r,i=[],o=function(e,t){t=K.isFunction(t)?t():null==t?\"\":t,i[i.length]=encodeURIComponent(e)+\"=\"+encodeURIComponent(t)};if(n===t&&(n=K.ajaxSettings&&K.ajaxSettings.traditional),K.isArray(e)||e.jquery&&!K.isPlainObject(e))K.each(e,function(){o(this.name,this.value)});else for(r in e)N(r,e[r],n,o);return i.join(\"&\").replace(bt,\"+\")};var Ct,kt,Et=/#.*$/,St=/^(.*?):[ \\t]*([^\\r\\n]*)\\r?$/gm,jt=/^(?:about|app|app\\-storage|.+\\-extension|file|res|widget):$/,At=/^(?:GET|HEAD)$/,Lt=/^\\/\\//,Dt=/\\?/,Ht=/<script\\b[^<]*(?:(?!<\\/script>)<[^<]*)*<\\/script>/gi,Ft=/([?&])_=[^&]*/,Mt=/^([\\w\\+\\.\\-]+:)(?:\\/\\/([^\\/?#:]*)(?::(\\d+)|)|)/,Ot=K.fn.load,qt={},_t={},Bt=[\"*/\"]+[\"*\"];try{kt=$.href}catch(Wt){kt=R.createElement(\"a\"),kt.href=\"\",kt=kt.href}Ct=Mt.exec(kt.toLowerCase())||[],K.fn.load=function(e,n,r){if(\"string\"!=typeof e&&Ot)return Ot.apply(this,arguments);if(!this.length)return this;var i,o,a,s=this,l=e.indexOf(\" \");return l>=0&&(i=e.slice(l,e.length),e=e.slice(0,l)),K.isFunction(n)?(r=n,n=t):n&&\"object\"==typeof n&&(o=\"POST\"),K.ajax({url:e,type:o,dataType:\"html\",data:n,complete:function(e,t){r&&s.each(r,a||[e.responseText,t,e])}}).done(function(e){a=arguments,s.html(i?K(\"<div>\").append(e.replace(Ht,\"\")).find(i):e)}),this},K.each(\"ajaxStart ajaxStop ajaxComplete ajaxError ajaxSuccess ajaxSend\".split(\" \"),function(e,t){K.fn[t]=function(e){return this.on(t,e)}}),K.each([\"get\",\"post\"],function(e,n){K[n]=function(e,r,i,o){return K.isFunction(r)&&(o=o||i,i=r,r=t),K.ajax({type:n,url:e,data:r,success:i,dataType:o})}}),K.extend({getScript:function(e,n){return K.get(e,t,n,\"script\")},getJSON:function(e,t,n){return K.get(e,t,n,\"json\")},ajaxSetup:function(e,t){return t?E(e,K.ajaxSettings):(t=e,e=K.ajaxSettings),E(e,t),e},ajaxSettings:{url:kt,isLocal:jt.test(Ct[1]),global:!0,type:\"GET\",contentType:\"application/x-www-form-urlencoded; charset=UTF-8\",processData:!0,async:!0,accepts:{xml:\"application/xml, text/xml\",html:\"text/html\",text:\"text/plain\",json:\"application/json, text/javascript\",\"*\":Bt},contents:{xml:/xml/,html:/html/,json:/json/},responseFields:{xml:\"responseXML\",text:\"responseText\"},converters:{\"* text\":e.String,\"text html\":!0,\"text json\":K.parseJSON,\"text xml\":K.parseXML},flatOptions:{context:!0,url:!0}},ajaxPrefilter:C(qt),ajaxTransport:C(_t),ajax:function(e,n){function r(e,n,r,a){var u,f,v,b,w,N=n;2!==x&&(x=2,l&&clearTimeout(l),s=t,o=a||\"\",T.readyState=e>0?4:0,r&&(b=S(p,T,r)),e>=200&&300>e||304===e?(p.ifModified&&(w=T.getResponseHeader(\"Last-Modified\"),w&&(K.lastModified[i]=w),w=T.getResponseHeader(\"Etag\"),w&&(K.etag[i]=w)),304===e?(N=\"notmodified\",u=!0):(u=j(p,b),N=u.state,f=u.data,v=u.error,u=!v)):(v=N,(!N||e)&&(N=\"error\",0>e&&(e=0))),T.status=e,T.statusText=(n||N)+\"\",u?g.resolveWith(d,[f,N,T]):g.rejectWith(d,[T,N,v]),T.statusCode(y),y=t,c&&h.trigger(\"ajax\"+(u?\"Success\":\"Error\"),[T,p,u?f:v]),m.fireWith(d,[T,N]),c&&(h.trigger(\"ajaxComplete\",[T,p]),--K.active||K.event.trigger(\"ajaxStop\")))}\"object\"==typeof e&&(n=e,e=t),n=n||{};var i,o,a,s,l,u,c,f,p=K.ajaxSetup({},n),d=p.context||p,h=d!==p&&(d.nodeType||d instanceof K)?K(d):K.event,g=K.Deferred(),m=K.Callbacks(\"once memory\"),y=p.statusCode||{},v={},b={},x=0,w=\"canceled\",T={readyState:0,setRequestHeader:function(e,t){if(!x){var n=e.toLowerCase();e=b[n]=b[n]||e,v[e]=t}return this},getAllResponseHeaders:function(){return 2===x?o:null},getResponseHeader:function(e){var n;if(2===x){if(!a)for(a={};n=St.exec(o);)a[n[1].toLowerCase()]=n[2];n=a[e.toLowerCase()]}return n===t?null:n},overrideMimeType:function(e){return x||(p.mimeType=e),this},abort:function(e){return e=e||w,s&&s.abort(e),r(0,e),this}};if(g.promise(T),T.success=T.done,T.error=T.fail,T.complete=m.add,T.statusCode=function(e){if(e){var t;if(2>x)for(t in e)y[t]=[y[t],e[t]];else t=e[T.status],T.always(t)}return this},p.url=((e||p.url)+\"\").replace(Et,\"\").replace(Lt,Ct[1]+\"//\"),p.dataTypes=K.trim(p.dataType||\"*\").toLowerCase().split(te),null==p.crossDomain&&(u=Mt.exec(p.url.toLowerCase()),p.crossDomain=!(!u||u[1]===Ct[1]&&u[2]===Ct[2]&&(u[3]||(\"http:\"===u[1]?80:443))==(Ct[3]||(\"http:\"===Ct[1]?80:443)))),p.data&&p.processData&&\"string\"!=typeof p.data&&(p.data=K.param(p.data,p.traditional)),k(qt,p,n,T),2===x)return T;if(c=p.global,p.type=p.type.toUpperCase(),p.hasContent=!At.test(p.type),c&&0===K.active++&&K.event.trigger(\"ajaxStart\"),!p.hasContent&&(p.data&&(p.url+=(Dt.test(p.url)?\"&\":\"?\")+p.data,delete p.data),i=p.url,p.cache===!1)){var N=K.now(),C=p.url.replace(Ft,\"$1_=\"+N);p.url=C+(C===p.url?(Dt.test(p.url)?\"&\":\"?\")+\"_=\"+N:\"\")}(p.data&&p.hasContent&&p.contentType!==!1||n.contentType)&&T.setRequestHeader(\"Content-Type\",p.contentType),p.ifModified&&(i=i||p.url,K.lastModified[i]&&T.setRequestHeader(\"If-Modified-Since\",K.lastModified[i]),K.etag[i]&&T.setRequestHeader(\"If-None-Match\",K.etag[i])),T.setRequestHeader(\"Accept\",p.dataTypes[0]&&p.accepts[p.dataTypes[0]]?p.accepts[p.dataTypes[0]]+(\"*\"!==p.dataTypes[0]?\", \"+Bt+\"; q=0.01\":\"\"):p.accepts[\"*\"]);for(f in p.headers)T.setRequestHeader(f,p.headers[f]);if(!p.beforeSend||p.beforeSend.call(d,T,p)!==!1&&2!==x){w=\"abort\";for(f in{success:1,error:1,complete:1})T[f](p[f]);if(s=k(_t,p,n,T)){T.readyState=1,c&&h.trigger(\"ajaxSend\",[T,p]),p.async&&p.timeout>0&&(l=setTimeout(function(){T.abort(\"timeout\")},p.timeout));try{x=1,s.send(v,r)}catch(E){if(!(2>x))throw E;r(-1,E)}}else r(-1,\"No Transport\");return T}return T.abort()},active:0,lastModified:{},etag:{}});var Pt=[],Rt=/\\?/,$t=/(=)\\?(?=&|$)|\\?\\?/,It=K.now();K.ajaxSetup({jsonp:\"callback\",jsonpCallback:function(){var e=Pt.pop()||K.expando+\"_\"+It++;return this[e]=!0,e}}),K.ajaxPrefilter(\"json jsonp\",function(n,r,i){var o,a,s,l=n.data,u=n.url,c=n.jsonp!==!1,f=c&&$t.test(u),p=c&&!f&&\"string\"==typeof l&&!(n.contentType||\"\").indexOf(\"application/x-www-form-urlencoded\")&&$t.test(l);return\"jsonp\"===n.dataTypes[0]||f||p?(o=n.jsonpCallback=K.isFunction(n.jsonpCallback)?n.jsonpCallback():n.jsonpCallback,a=e[o],f?n.url=u.replace($t,\"$1\"+o):p?n.data=l.replace($t,\"$1\"+o):c&&(n.url+=(Rt.test(u)?\"&\":\"?\")+n.jsonp+\"=\"+o),n.converters[\"script json\"]=function(){return s||K.error(o+\" was not called\"),s[0]},n.dataTypes[0]=\"json\",e[o]=function(){s=arguments},i.always(function(){e[o]=a,n[o]&&(n.jsonpCallback=r.jsonpCallback,Pt.push(o)),s&&K.isFunction(a)&&a(s[0]),s=a=t}),\"script\"):void 0}),K.ajaxSetup({accepts:{script:\"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript\"},contents:{script:/javascript|ecmascript/},converters:{\"text script\":function(e){return K.globalEval(e),e}}}),K.ajaxPrefilter(\"script\",function(e){e.cache===t&&(e.cache=!1),e.crossDomain&&(e.type=\"GET\",e.global=!1)}),K.ajaxTransport(\"script\",function(e){if(e.crossDomain){var n,r=R.head||R.getElementsByTagName(\"head\")[0]||R.documentElement;return{send:function(i,o){n=R.createElement(\"script\"),n.async=\"async\",e.scriptCharset&&(n.charset=e.scriptCharset),n.src=e.url,n.onload=n.onreadystatechange=function(e,i){(i||!n.readyState||/loaded|complete/.test(n.readyState))&&(n.onload=n.onreadystatechange=null,r&&n.parentNode&&r.removeChild(n),n=t,i||o(200,\"success\"))},r.insertBefore(n,r.firstChild)},abort:function(){n&&n.onload(0,1)}}}});var zt,Xt=e.ActiveXObject?function(){for(var e in zt)zt[e](0,1)}:!1,Ut=0;K.ajaxSettings.xhr=e.ActiveXObject?function(){return!this.isLocal&&A()||L()}:A,function(e){K.extend(K.support,{ajax:!!e,cors:!!e&&\"withCredentials\"in e})}(K.ajaxSettings.xhr()),K.support.ajax&&K.ajaxTransport(function(n){if(!n.crossDomain||K.support.cors){var r;return{send:function(i,o){var a,s,l=n.xhr();if(n.username?l.open(n.type,n.url,n.async,n.username,n.password):l.open(n.type,n.url,n.async),n.xhrFields)for(s in n.xhrFields)l[s]=n.xhrFields[s];n.mimeType&&l.overrideMimeType&&l.overrideMimeType(n.mimeType),!n.crossDomain&&!i[\"X-Requested-With\"]&&(i[\"X-Requested-With\"]=\"XMLHttpRequest\");try{for(s in i)l.setRequestHeader(s,i[s])}catch(u){}l.send(n.hasContent&&n.data||null),r=function(e,i){var s,u,c,f,p;try{if(r&&(i||4===l.readyState))if(r=t,a&&(l.onreadystatechange=K.noop,Xt&&delete zt[a]),i)4!==l.readyState&&l.abort();else{s=l.status,c=l.getAllResponseHeaders(),f={},p=l.responseXML,p&&p.documentElement&&(f.xml=p);try{f.text=l.responseText}catch(d){}try{u=l.statusText}catch(d){u=\"\"}s||!n.isLocal||n.crossDomain?1223===s&&(s=204):s=f.text?200:404}}catch(h){i||o(-1,h)}f&&o(s,u,f,c)},n.async?4===l.readyState?setTimeout(r,0):(a=++Ut,Xt&&(zt||(zt={},K(e).unload(Xt)),zt[a]=r),l.onreadystatechange=r):r()},abort:function(){r&&r(0,1)}}}});var Qt,Yt,Vt=/^(?:toggle|show|hide)$/,Jt=new RegExp(\"^(?:([-+])=|)(\"+Z+\")([a-z%]*)$\",\"i\"),Gt=/queueHooks$/,Kt=[O],Zt={\"*\":[function(e,t){var n,r,i=this.createTween(e,t),o=Jt.exec(t),a=i.cur(),s=+a||0,l=1,u=20;if(o){if(n=+o[2],r=o[3]||(K.cssNumber[e]?\"\":\"px\"),\"px\"!==r&&s){s=K.css(i.elem,e,!0)||n||1;do l=l||\".5\",s/=l,K.style(i.elem,e,s+r);while(l!==(l=i.cur()/a)&&1!==l&&--u)}i.unit=r,i.start=s,i.end=o[1]?s+(o[1]+1)*n:n}return i}]};K.Animation=K.extend(F,{tweener:function(e,t){K.isFunction(e)?(t=e,e=[\"*\"]):e=e.split(\" \");for(var n,r=0,i=e.length;i>r;r++)n=e[r],Zt[n]=Zt[n]||[],Zt[n].unshift(t)},prefilter:function(e,t){t?Kt.unshift(e):Kt.push(e)}}),K.Tween=q,q.prototype={constructor:q,init:function(e,t,n,r,i,o){this.elem=e,this.prop=n,this.easing=i||\"swing\",this.options=t,this.start=this.now=this.cur(),this.end=r,this.unit=o||(K.cssNumber[n]?\"\":\"px\")},cur:function(){var e=q.propHooks[this.prop];return e&&e.get?e.get(this):q.propHooks._default.get(this)},run:function(e){var t,n=q.propHooks[this.prop];return this.pos=t=this.options.duration?K.easing[this.easing](e,this.options.duration*e,0,1,this.options.duration):e,this.now=(this.end-this.start)*t+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),n&&n.set?n.set(this):q.propHooks._default.set(this),this}},q.prototype.init.prototype=q.prototype,q.propHooks={_default:{get:function(e){var t;return null==e.elem[e.prop]||e.elem.style&&null!=e.elem.style[e.prop]?(t=K.css(e.elem,e.prop,!1,\"\"),t&&\"auto\"!==t?t:0):e.elem[e.prop]},set:function(e){K.fx.step[e.prop]?K.fx.step[e.prop](e):e.elem.style&&(null!=e.elem.style[K.cssProps[e.prop]]||K.cssHooks[e.prop])?K.style(e.elem,e.prop,e.now+e.unit):e.elem[e.prop]=e.now}}},q.propHooks.scrollTop=q.propHooks.scrollLeft={set:function(e){e.elem.nodeType&&e.elem.parentNode&&(e.elem[e.prop]=e.now)}},K.each([\"toggle\",\"show\",\"hide\"],function(e,t){var n=K.fn[t];K.fn[t]=function(r,i,o){return null==r||\"boolean\"==typeof r||!e&&K.isFunction(r)&&K.isFunction(i)?n.apply(this,arguments):this.animate(_(t,!0),r,i,o)}}),K.fn.extend({fadeTo:function(e,t,n,r){return this.filter(y).css(\"opacity\",0).show().end().animate({opacity:t},e,n,r)},animate:function(e,t,n,r){var i=K.isEmptyObject(e),o=K.speed(t,n,r),a=function(){var t=F(this,K.extend({},e),o);i&&t.stop(!0)};return i||o.queue===!1?this.each(a):this.queue(o.queue,a)},stop:function(e,n,r){var i=function(e){var t=e.stop;delete e.stop,t(r)};return\"string\"!=typeof e&&(r=n,n=e,e=t),n&&e!==!1&&this.queue(e||\"fx\",[]),this.each(function(){var t=!0,n=null!=e&&e+\"queueHooks\",o=K.timers,a=K._data(this);if(n)a[n]&&a[n].stop&&i(a[n]);else for(n in a)a[n]&&a[n].stop&&Gt.test(n)&&i(a[n]);for(n=o.length;n--;)o[n].elem===this&&(null==e||o[n].queue===e)&&(o[n].anim.stop(r),t=!1,o.splice(n,1));(t||!r)&&K.dequeue(this,e)})}}),K.each({slideDown:_(\"show\"),slideUp:_(\"hide\"),slideToggle:_(\"toggle\"),fadeIn:{opacity:\"show\"},fadeOut:{opacity:\"hide\"},fadeToggle:{opacity:\"toggle\"}},function(e,t){K.fn[e]=function(e,n,r){return this.animate(t,e,n,r)}}),K.speed=function(e,t,n){var r=e&&\"object\"==typeof e?K.extend({},e):{complete:n||!n&&t||K.isFunction(e)&&e,duration:e,easing:n&&t||t&&!K.isFunction(t)&&t};return r.duration=K.fx.off?0:\"number\"==typeof r.duration?r.duration:r.duration in K.fx.speeds?K.fx.speeds[r.duration]:K.fx.speeds._default,(null==r.queue||r.queue===!0)&&(r.queue=\"fx\"),r.old=r.complete,r.complete=function(){K.isFunction(r.old)&&r.old.call(this),r.queue&&K.dequeue(this,r.queue)},r},K.easing={linear:function(e){return e},swing:function(e){return.5-Math.cos(e*Math.PI)/2}},K.timers=[],K.fx=q.prototype.init,K.fx.tick=function(){var e,n=K.timers,r=0;for(Qt=K.now();r<n.length;r++)e=n[r],!e()&&n[r]===e&&n.splice(r--,1);n.length||K.fx.stop(),Qt=t},K.fx.timer=function(e){e()&&K.timers.push(e)&&!Yt&&(Yt=setInterval(K.fx.tick,K.fx.interval))},K.fx.interval=13,K.fx.stop=function(){clearInterval(Yt),Yt=null},K.fx.speeds={slow:600,fast:200,_default:400},K.fx.step={},K.expr&&K.expr.filters&&(K.expr.filters.animated=function(e){return K.grep(K.timers,function(t){return e===t.elem}).length});var en=/^(?:body|html)$/i;K.fn.offset=function(e){if(arguments.length)return e===t?this:this.each(function(t){K.offset.setOffset(this,e,t)});var n,r,i,o,a,s,l,u={top:0,left:0},c=this[0],f=c&&c.ownerDocument;if(f)return(r=f.body)===c?K.offset.bodyOffset(c):(n=f.documentElement,K.contains(n,c)?(\"undefined\"!=typeof c.getBoundingClientRect&&(u=c.getBoundingClientRect()),i=B(f),o=n.clientTop||r.clientTop||0,a=n.clientLeft||r.clientLeft||0,s=i.pageYOffset||n.scrollTop,l=i.pageXOffset||n.scrollLeft,{top:u.top+s-o,left:u.left+l-a}):u)},K.offset={bodyOffset:function(e){var t=e.offsetTop,n=e.offsetLeft;return K.support.doesNotIncludeMarginInBodyOffset&&(t+=parseFloat(K.css(e,\"marginTop\"))||0,n+=parseFloat(K.css(e,\"marginLeft\"))||0),{top:t,left:n}},setOffset:function(e,t,n){var r=K.css(e,\"position\");\"static\"===r&&(e.style.position=\"relative\");var i,o,a=K(e),s=a.offset(),l=K.css(e,\"top\"),u=K.css(e,\"left\"),c=(\"absolute\"===r||\"fixed\"===r)&&K.inArray(\"auto\",[l,u])>-1,f={},p={};c?(p=a.position(),i=p.top,o=p.left):(i=parseFloat(l)||0,o=parseFloat(u)||0),K.isFunction(t)&&(t=t.call(e,n,s)),null!=t.top&&(f.top=t.top-s.top+i),null!=t.left&&(f.left=t.left-s.left+o),\"using\"in t?t.using.call(e,f):a.css(f)}},K.fn.extend({position:function(){if(this[0]){var e=this[0],t=this.offsetParent(),n=this.offset(),r=en.test(t[0].nodeName)?{top:0,left:0}:t.offset();return n.top-=parseFloat(K.css(e,\"marginTop\"))||0,n.left-=parseFloat(K.css(e,\"marginLeft\"))||0,r.top+=parseFloat(K.css(t[0],\"borderTopWidth\"))||0,r.left+=parseFloat(K.css(t[0],\"borderLeftWidth\"))||0,{top:n.top-r.top,left:n.left-r.left}}},offsetParent:function(){return this.map(function(){for(var e=this.offsetParent||R.body;e&&!en.test(e.nodeName)&&\"static\"===K.css(e,\"position\");)e=e.offsetParent;return e||R.body})}}),K.each({scrollLeft:\"pageXOffset\",scrollTop:\"pageYOffset\"},function(e,n){var r=/Y/.test(n);K.fn[e]=function(i){return K.access(this,function(e,i,o){var a=B(e);return o===t?a?n in a?a[n]:a.document.documentElement[i]:e[i]:void(a?a.scrollTo(r?K(a).scrollLeft():o,r?o:K(a).scrollTop()):e[i]=o)},e,i,arguments.length,null)}}),K.each({Height:\"height\",Width:\"width\"},function(e,n){K.each({padding:\"inner\"+e,content:n,\"\":\"outer\"+e},function(r,i){K.fn[i]=function(i,o){var a=arguments.length&&(r||\"boolean\"!=typeof i),s=r||(i===!0||o===!0?\"margin\":\"border\");return K.access(this,function(n,r,i){var o;return K.isWindow(n)?n.document.documentElement[\"client\"+e]:9===n.nodeType?(o=n.documentElement,Math.max(n.body[\"scroll\"+e],o[\"scroll\"+e],n.body[\"offset\"+e],o[\"offset\"+e],o[\"client\"+e])):i===t?K.css(n,r,i,s):K.style(n,r,i,s)},n,a?i:t,a,null)}})}),e.jQuery=e.$=K,\"function\"==typeof define&&define.amd&&define.amd.jQuery&&define(\"jquery\",[],function(){return K})}(window),window.lofty&&(jQuery.noConflict(),define(\"gallery/jquery/jqueryLatest\",function(){return jQuery}),lofty.config({alias:{jquery:\"gallery/jquery/jqueryLatest\"}})),function(e){var t=0===location.protocol.indexOf(\"https\")?\"https://\":\"http://\",n=function(e){return\"string\"==typeof e?e.replace(/^(?:http:)?\\/\\//i,t):e},r=e.ajax;e.ajax=function(t,i){return\"object\"==typeof t?(i=t,\"undefined\"!=typeof i.url&&(i.url=n(i.url)),r.call(e,i)):r.call(e,n(t),i)}}(jQuery);;");
            System.out.println("write to file success : " + file.getPath());
        } catch (IOException e) {
            e.printStackTrace();
        } finally {
            MybatisUtilCommon.closeBufferWriterAndFileOutputStream(fileOutputStream, bufferedWriter);
        }
    }

    public static void writeCommonPageCommonJsJqueryUiJs(String htmlPath, String serverUrl) {
        File file = null;
        OutputStream fileOutputStream = null;
        BufferedWriter bufferedWriter = null;
        try {
            File folder = new File(htmlPath + "/common/page-common/js/");
            folder.mkdirs();
            file = new File(htmlPath + "/common/page-common/js/jquery-ui.js");
            //如果文件不存在，则创建文件，如果已存在，则覆盖
            file.createNewFile();
            fileOutputStream = new FileOutputStream(file);
            bufferedWriter = new BufferedWriter(new OutputStreamWriter(fileOutputStream, "utf-8"));
            bufferedWriter.write("(function(t,e){function i(e,i){var n,o,a,r=e.nodeName.toLowerCase();return\"area\"===r?(n=e.parentNode,o=n.name,e.href&&o&&\"map\"===n.nodeName.toLowerCase()?(a=t(\"img[usemap=#\"+o+\"]\")[0],!!a&&s(a)):!1):(/input|select|textarea|button|object/.test(r)?!e.disabled:\"a\"===r?e.href||i:i)&&s(e)}function s(e){return t.expr.filters.visible(e)&&!t(e).parents().addBack().filter(function(){return\"hidden\"===t.css(this,\"visibility\")}).length}var n=0,o=/^ui-id-\\d+$/;t.ui=t.ui||{},t.extend(t.ui,{version:\"1.10.4\",keyCode:{BACKSPACE:8,COMMA:188,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,LEFT:37,NUMPAD_ADD:107,NUMPAD_DECIMAL:110,NUMPAD_DIVIDE:111,NUMPAD_ENTER:108,NUMPAD_MULTIPLY:106,NUMPAD_SUBTRACT:109,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SPACE:32,TAB:9,UP:38}}),t.fn.extend({focus:function(e){return function(i,s){return\"number\"==typeof i?this.each(function(){var e=this;setTimeout(function(){t(e).focus(),s&&s.call(e)},i)}):e.apply(this,arguments)}}(t.fn.focus),scrollParent:function(){var e;return e=t.ui.ie&&/(static|relative)/.test(this.css(\"position\"))||/absolute/.test(this.css(\"position\"))?this.parents().filter(function(){return/(relative|absolute|fixed)/.test(t.css(this,\"position\"))&&/(auto|scroll)/.test(t.css(this,\"overflow\")+t.css(this,\"overflow-y\")+t.css(this,\"overflow-x\"))}).eq(0):this.parents().filter(function(){return/(auto|scroll)/.test(t.css(this,\"overflow\")+t.css(this,\"overflow-y\")+t.css(this,\"overflow-x\"))}).eq(0),/fixed/.test(this.css(\"position\"))||!e.length?t(document):e},zIndex:function(i){if(i!==e)return this.css(\"zIndex\",i);if(this.length)for(var s,n,o=t(this[0]);o.length&&o[0]!==document;){if(s=o.css(\"position\"),(\"absolute\"===s||\"relative\"===s||\"fixed\"===s)&&(n=parseInt(o.css(\"zIndex\"),10),!isNaN(n)&&0!==n))return n;o=o.parent()}return 0},uniqueId:function(){return this.each(function(){this.id||(this.id=\"ui-id-\"+ ++n)})},removeUniqueId:function(){return this.each(function(){o.test(this.id)&&t(this).removeAttr(\"id\")})}}),t.extend(t.expr[\":\"],{data:t.expr.createPseudo?t.expr.createPseudo(function(e){return function(i){return!!t.data(i,e)}}):function(e,i,s){return!!t.data(e,s[3])},focusable:function(e){return i(e,!isNaN(t.attr(e,\"tabindex\")))},tabbable:function(e){var s=t.attr(e,\"tabindex\"),n=isNaN(s);return(n||s>=0)&&i(e,!n)}}),t(\"<a>\").outerWidth(1).jquery||t.each([\"Width\",\"Height\"],function(i,s){function n(e,i,s,n){return t.each(o,function(){i-=parseFloat(t.css(e,\"padding\"+this))||0,s&&(i-=parseFloat(t.css(e,\"border\"+this+\"Width\"))||0),n&&(i-=parseFloat(t.css(e,\"margin\"+this))||0)}),i}var o=\"Width\"===s?[\"Left\",\"Right\"]:[\"Top\",\"Bottom\"],a=s.toLowerCase(),r={innerWidth:t.fn.innerWidth,innerHeight:t.fn.innerHeight,outerWidth:t.fn.outerWidth,outerHeight:t.fn.outerHeight};t.fn[\"inner\"+s]=function(i){return i===e?r[\"inner\"+s].call(this):this.each(function(){t(this).css(a,n(this,i)+\"px\")})},t.fn[\"outer\"+s]=function(e,i){return\"number\"!=typeof e?r[\"outer\"+s].call(this,e):this.each(function(){t(this).css(a,n(this,e,!0,i)+\"px\")})}}),t.fn.addBack||(t.fn.addBack=function(t){return this.add(null==t?this.prevObject:this.prevObject.filter(t))}),t(\"<a>\").data(\"a-b\",\"a\").removeData(\"a-b\").data(\"a-b\")&&(t.fn.removeData=function(e){return function(i){return arguments.length?e.call(this,t.camelCase(i)):e.call(this)}}(t.fn.removeData)),t.ui.ie=!!/msie [\\w.]+/.exec(navigator.userAgent.toLowerCase()),t.support.selectstart=\"onselectstart\"in document.createElement(\"div\"),t.fn.extend({disableSelection:function(){return this.bind((t.support.selectstart?\"selectstart\":\"mousedown\")+\".ui-disableSelection\",function(t){t.preventDefault()})},enableSelection:function(){return this.unbind(\".ui-disableSelection\")}}),t.extend(t.ui,{plugin:{add:function(e,i,s){var n,o=t.ui[e].prototype;for(n in s)o.plugins[n]=o.plugins[n]||[],o.plugins[n].push([i,s[n]])},call:function(t,e,i){var s,n=t.plugins[e];if(n&&t.element[0].parentNode&&11!==t.element[0].parentNode.nodeType)for(s=0;n.length>s;s++)t.options[n[s][0]]&&n[s][1].apply(t.element,i)}},hasScroll:function(e,i){if(\"hidden\"===t(e).css(\"overflow\"))return!1;var s=i&&\"left\"===i?\"scrollLeft\":\"scrollTop\",n=!1;return e[s]>0?!0:(e[s]=1,n=e[s]>0,e[s]=0,n)}})})(jQuery),function(t,e){var i=0,s=Array.prototype.slice,n=t.cleanData;t.cleanData=function(e){for(var i,s=0;null!=(i=e[s]);s++)try{t(i).triggerHandler(\"remove\")}catch(o){}n(e)},t.widget=function(i,s,n){var o,a,r,h,l={},c=i.split(\".\")[0];i=i.split(\".\")[1],o=c+\"-\"+i,n||(n=s,s=t.Widget),t.expr[\":\"][o.toLowerCase()]=function(e){return!!t.data(e,o)},t[c]=t[c]||{},a=t[c][i],r=t[c][i]=function(t,i){return this._createWidget?(arguments.length&&this._createWidget(t,i),e):new r(t,i)},t.extend(r,a,{version:n.version,_proto:t.extend({},n),_childConstructors:[]}),h=new s,h.options=t.widget.extend({},h.options),t.each(n,function(i,n){return t.isFunction(n)?(l[i]=function(){var t=function(){return s.prototype[i].apply(this,arguments)},e=function(t){return s.prototype[i].apply(this,t)};return function(){var i,s=this._super,o=this._superApply;return this._super=t,this._superApply=e,i=n.apply(this,arguments),this._super=s,this._superApply=o,i}}(),e):(l[i]=n,e)}),r.prototype=t.widget.extend(h,{widgetEventPrefix:a?h.widgetEventPrefix||i:i},l,{constructor:r,namespace:c,widgetName:i,widgetFullName:o}),a?(t.each(a._childConstructors,function(e,i){var s=i.prototype;t.widget(s.namespace+\".\"+s.widgetName,r,i._proto)}),delete a._childConstructors):s._childConstructors.push(r),t.widget.bridge(i,r)},t.widget.extend=function(i){for(var n,o,a=s.call(arguments,1),r=0,h=a.length;h>r;r++)for(n in a[r])o=a[r][n],a[r].hasOwnProperty(n)&&o!==e&&(i[n]=t.isPlainObject(o)?t.isPlainObject(i[n])?t.widget.extend({},i[n],o):t.widget.extend({},o):o);return i},t.widget.bridge=function(i,n){var o=n.prototype.widgetFullName||i;t.fn[i]=function(a){var r=\"string\"==typeof a,h=s.call(arguments,1),l=this;return a=!r&&h.length?t.widget.extend.apply(null,[a].concat(h)):a,r?this.each(function(){var s,n=t.data(this,o);return n?t.isFunction(n[a])&&\"_\"!==a.charAt(0)?(s=n[a].apply(n,h),s!==n&&s!==e?(l=s&&s.jquery?l.pushStack(s.get()):s,!1):e):t.error(\"no such method '\"+a+\"' for \"+i+\" widget instance\"):t.error(\"cannot call methods on \"+i+\" prior to initialization; \"+\"attempted to call method '\"+a+\"'\")}):this.each(function(){var e=t.data(this,o);e?e.option(a||{})._init():t.data(this,o,new n(a,this))}),l}},t.Widget=function(){},t.Widget._childConstructors=[],t.Widget.prototype={widgetName:\"widget\",widgetEventPrefix:\"\",defaultElement:\"<div>\",options:{disabled:!1,create:null},_createWidget:function(e,s){s=t(s||this.defaultElement||this)[0],this.element=t(s),this.uuid=i++,this.eventNamespace=\".\"+this.widgetName+this.uuid,this.options=t.widget.extend({},this.options,this._getCreateOptions(),e),this.bindings=t(),this.hoverable=t(),this.focusable=t(),s!==this&&(t.data(s,this.widgetFullName,this),this._on(!0,this.element,{remove:function(t){t.target===s&&this.destroy()}}),this.document=t(s.style?s.ownerDocument:s.document||s),this.window=t(this.document[0].defaultView||this.document[0].parentWindow)),this._create(),this._trigger(\"create\",null,this._getCreateEventData()),this._init()},_getCreateOptions:t.noop,_getCreateEventData:t.noop,_create:t.noop,_init:t.noop,destroy:function(){this._destroy(),this.element.unbind(this.eventNamespace).removeData(this.widgetName).removeData(this.widgetFullName).removeData(t.camelCase(this.widgetFullName)),this.widget().unbind(this.eventNamespace).removeAttr(\"aria-disabled\").removeClass(this.widgetFullName+\"-disabled \"+\"ui-state-disabled\"),this.bindings.unbind(this.eventNamespace),this.hoverable.removeClass(\"ui-state-hover\"),this.focusable.removeClass(\"ui-state-focus\")},_destroy:t.noop,widget:function(){return this.element},option:function(i,s){var n,o,a,r=i;if(0===arguments.length)return t.widget.extend({},this.options);if(\"string\"==typeof i)if(r={},n=i.split(\".\"),i=n.shift(),n.length){for(o=r[i]=t.widget.extend({},this.options[i]),a=0;n.length-1>a;a++)o[n[a]]=o[n[a]]||{},o=o[n[a]];if(i=n.pop(),1===arguments.length)return o[i]===e?null:o[i];o[i]=s}else{if(1===arguments.length)return this.options[i]===e?null:this.options[i];r[i]=s}return this._setOptions(r),this},_setOptions:function(t){var e;for(e in t)this._setOption(e,t[e]);return this},_setOption:function(t,e){return this.options[t]=e,\"disabled\"===t&&(this.widget().toggleClass(this.widgetFullName+\"-disabled ui-state-disabled\",!!e).attr(\"aria-disabled\",e),this.hoverable.removeClass(\"ui-state-hover\"),this.focusable.removeClass(\"ui-state-focus\")),this},enable:function(){return this._setOption(\"disabled\",!1)},disable:function(){return this._setOption(\"disabled\",!0)},_on:function(i,s,n){var o,a=this;\"boolean\"!=typeof i&&(n=s,s=i,i=!1),n?(s=o=t(s),this.bindings=this.bindings.add(s)):(n=s,s=this.element,o=this.widget()),t.each(n,function(n,r){function h(){return i||a.options.disabled!==!0&&!t(this).hasClass(\"ui-state-disabled\")?(\"string\"==typeof r?a[r]:r).apply(a,arguments):e}\"string\"!=typeof r&&(h.guid=r.guid=r.guid||h.guid||t.guid++);var l=n.match(/^(\\w+)\\s*(.*)$/),c=l[1]+a.eventNamespace,u=l[2];u?o.delegate(u,c,h):s.bind(c,h)})},_off:function(t,e){e=(e||\"\").split(\" \").join(this.eventNamespace+\" \")+this.eventNamespace,t.unbind(e).undelegate(e)},_delay:function(t,e){function i(){return(\"string\"==typeof t?s[t]:t).apply(s,arguments)}var s=this;return setTimeout(i,e||0)},_hoverable:function(e){this.hoverable=this.hoverable.add(e),this._on(e,{mouseenter:function(e){t(e.currentTarget).addClass(\"ui-state-hover\")},mouseleave:function(e){t(e.currentTarget).removeClass(\"ui-state-hover\")}})},_focusable:function(e){this.focusable=this.focusable.add(e),this._on(e,{focusin:function(e){t(e.currentTarget).addClass(\"ui-state-focus\")},focusout:function(e){t(e.currentTarget).removeClass(\"ui-state-focus\")}})},_trigger:function(e,i,s){var n,o,a=this.options[e];if(s=s||{},i=t.Event(i),i.type=(e===this.widgetEventPrefix?e:this.widgetEventPrefix+e).toLowerCase(),i.target=this.element[0],o=i.originalEvent)for(n in o)n in i||(i[n]=o[n]);return this.element.trigger(i,s),!(t.isFunction(a)&&a.apply(this.element[0],[i].concat(s))===!1||i.isDefaultPrevented())}},t.each({show:\"fadeIn\",hide:\"fadeOut\"},function(e,i){t.Widget.prototype[\"_\"+e]=function(s,n,o){\"string\"==typeof n&&(n={effect:n});var a,r=n?n===!0||\"number\"==typeof n?i:n.effect||i:e;n=n||{},\"number\"==typeof n&&(n={duration:n}),a=!t.isEmptyObject(n),n.complete=o,n.delay&&s.delay(n.delay),a&&t.effects&&t.effects.effect[r]?s[e](n):r!==e&&s[r]?s[r](n.duration,n.easing,o):s.queue(function(i){t(this)[e](),o&&o.call(s[0]),i()})}})}(jQuery),function(t){var e=!1;t(document).mouseup(function(){e=!1}),t.widget(\"ui.mouse\",{version:\"1.10.4\",options:{cancel:\"input,textarea,button,select,option\",distance:1,delay:0},_mouseInit:function(){var e=this;this.element.bind(\"mousedown.\"+this.widgetName,function(t){return e._mouseDown(t)}).bind(\"click.\"+this.widgetName,function(i){return!0===t.data(i.target,e.widgetName+\".preventClickEvent\")?(t.removeData(i.target,e.widgetName+\".preventClickEvent\"),i.stopImmediatePropagation(),!1):undefined}),this.started=!1},_mouseDestroy:function(){this.element.unbind(\".\"+this.widgetName),this._mouseMoveDelegate&&t(document).unbind(\"mousemove.\"+this.widgetName,this._mouseMoveDelegate).unbind(\"mouseup.\"+this.widgetName,this._mouseUpDelegate)},_mouseDown:function(i){if(!e){this._mouseStarted&&this._mouseUp(i),this._mouseDownEvent=i;var s=this,n=1===i.which,o=\"string\"==typeof this.options.cancel&&i.target.nodeName?t(i.target).closest(this.options.cancel).length:!1;return n&&!o&&this._mouseCapture(i)?(this.mouseDelayMet=!this.options.delay,this.mouseDelayMet||(this._mouseDelayTimer=setTimeout(function(){s.mouseDelayMet=!0},this.options.delay)),this._mouseDistanceMet(i)&&this._mouseDelayMet(i)&&(this._mouseStarted=this._mouseStart(i)!==!1,!this._mouseStarted)?(i.preventDefault(),!0):(!0===t.data(i.target,this.widgetName+\".preventClickEvent\")&&t.removeData(i.target,this.widgetName+\".preventClickEvent\"),this._mouseMoveDelegate=function(t){return s._mouseMove(t)},this._mouseUpDelegate=function(t){return s._mouseUp(t)},t(document).bind(\"mousemove.\"+this.widgetName,this._mouseMoveDelegate).bind(\"mouseup.\"+this.widgetName,this._mouseUpDelegate),i.preventDefault(),e=!0,!0)):!0}},_mouseMove:function(e){return t.ui.ie&&(!document.documentMode||9>document.documentMode)&&!e.button?this._mouseUp(e):this._mouseStarted?(this._mouseDrag(e),e.preventDefault()):(this._mouseDistanceMet(e)&&this._mouseDelayMet(e)&&(this._mouseStarted=this._mouseStart(this._mouseDownEvent,e)!==!1,this._mouseStarted?this._mouseDrag(e):this._mouseUp(e)),!this._mouseStarted)},_mouseUp:function(e){return t(document).unbind(\"mousemove.\"+this.widgetName,this._mouseMoveDelegate).unbind(\"mouseup.\"+this.widgetName,this._mouseUpDelegate),this._mouseStarted&&(this._mouseStarted=!1,e.target===this._mouseDownEvent.target&&t.data(e.target,this.widgetName+\".preventClickEvent\",!0),this._mouseStop(e)),!1},_mouseDistanceMet:function(t){return Math.max(Math.abs(this._mouseDownEvent.pageX-t.pageX),Math.abs(this._mouseDownEvent.pageY-t.pageY))>=this.options.distance},_mouseDelayMet:function(){return this.mouseDelayMet},_mouseStart:function(){},_mouseDrag:function(){},_mouseStop:function(){},_mouseCapture:function(){return!0}})}(jQuery),function(t){t.widget(\"ui.draggable\",t.ui.mouse,{version:\"1.10.4\",widgetEventPrefix:\"drag\",options:{addClasses:!0,appendTo:\"parent\",axis:!1,connectToSortable:!1,containment:!1,cursor:\"auto\",cursorAt:!1,grid:!1,handle:!1,helper:\"original\",iframeFix:!1,opacity:!1,refreshPositions:!1,revert:!1,revertDuration:500,scope:\"default\",scroll:!0,scrollSensitivity:20,scrollSpeed:20,snap:!1,snapMode:\"both\",snapTolerance:20,stack:!1,zIndex:!1,drag:null,start:null,stop:null},_create:function(){\"original\"!==this.options.helper||/^(?:r|a|f)/.test(this.element.css(\"position\"))||(this.element[0].style.position=\"relative\"),this.options.addClasses&&this.element.addClass(\"ui-draggable\"),this.options.disabled&&this.element.addClass(\"ui-draggable-disabled\"),this._mouseInit()},_destroy:function(){this.element.removeClass(\"ui-draggable ui-draggable-dragging ui-draggable-disabled\"),this._mouseDestroy()},_mouseCapture:function(e){var i=this.options;return this.helper||i.disabled||t(e.target).closest(\".ui-resizable-handle\").length>0?!1:(this.handle=this._getHandle(e),this.handle?(t(i.iframeFix===!0?\"iframe\":i.iframeFix).each(function(){t(\"<div class='ui-draggable-iframeFix' style='background: #fff;'></div>\").css({width:this.offsetWidth+\"px\",height:this.offsetHeight+\"px\",position:\"absolute\",opacity:\"0.001\",zIndex:1e3}).css(t(this).offset()).appendTo(\"body\")}),!0):!1)},_mouseStart:function(e){var i=this.options;return this.helper=this._createHelper(e),this.helper.addClass(\"ui-draggable-dragging\"),this._cacheHelperProportions(),t.ui.ddmanager&&(t.ui.ddmanager.current=this),this._cacheMargins(),this.cssPosition=this.helper.css(\"position\"),this.scrollParent=this.helper.scrollParent(),this.offsetParent=this.helper.offsetParent(),this.offsetParentCssPosition=this.offsetParent.css(\"position\"),this.offset=this.positionAbs=this.element.offset(),this.offset={top:this.offset.top-this.margins.top,left:this.offset.left-this.margins.left},this.offset.scroll=!1,t.extend(this.offset,{click:{left:e.pageX-this.offset.left,top:e.pageY-this.offset.top},parent:this._getParentOffset(),relative:this._getRelativeOffset()}),this.originalPosition=this.position=this._generatePosition(e),this.originalPageX=e.pageX,this.originalPageY=e.pageY,i.cursorAt&&this._adjustOffsetFromHelper(i.cursorAt),this._setContainment(),this._trigger(\"start\",e)===!1?(this._clear(),!1):(this._cacheHelperProportions(),t.ui.ddmanager&&!i.dropBehaviour&&t.ui.ddmanager.prepareOffsets(this,e),this._mouseDrag(e,!0),t.ui.ddmanager&&t.ui.ddmanager.dragStart(this,e),!0)},_mouseDrag:function(e,i){if(\"fixed\"===this.offsetParentCssPosition&&(this.offset.parent=this._getParentOffset()),this.position=this._generatePosition(e),this.positionAbs=this._convertPositionTo(\"absolute\"),!i){var s=this._uiHash();if(this._trigger(\"drag\",e,s)===!1)return this._mouseUp({}),!1;this.position=s.position}return this.options.axis&&\"y\"===this.options.axis||(this.helper[0].style.left=this.position.left+\"px\"),this.options.axis&&\"x\"===this.options.axis||(this.helper[0].style.top=this.position.top+\"px\"),t.ui.ddmanager&&t.ui.ddmanager.drag(this,e),!1},_mouseStop:function(e){var i=this,s=!1;return t.ui.ddmanager&&!this.options.dropBehaviour&&(s=t.ui.ddmanager.drop(this,e)),this.dropped&&(s=this.dropped,this.dropped=!1),\"original\"!==this.options.helper||t.contains(this.element[0].ownerDocument,this.element[0])?(\"invalid\"===this.options.revert&&!s||\"valid\"===this.options.revert&&s||this.options.revert===!0||t.isFunction(this.options.revert)&&this.options.revert.call(this.element,s)?t(this.helper).animate(this.originalPosition,parseInt(this.options.revertDuration,10),function(){i._trigger(\"stop\",e)!==!1&&i._clear()}):this._trigger(\"stop\",e)!==!1&&this._clear(),!1):!1},_mouseUp:function(e){return t(\"div.ui-draggable-iframeFix\").each(function(){this.parentNode.removeChild(this)}),t.ui.ddmanager&&t.ui.ddmanager.dragStop(this,e),t.ui.mouse.prototype._mouseUp.call(this,e)},cancel:function(){return this.helper.is(\".ui-draggable-dragging\")?this._mouseUp({}):this._clear(),this},_getHandle:function(e){return this.options.handle?!!t(e.target).closest(this.element.find(this.options.handle)).length:!0},_createHelper:function(e){var i=this.options,s=t.isFunction(i.helper)?t(i.helper.apply(this.element[0],[e])):\"clone\"===i.helper?this.element.clone().removeAttr(\"id\"):this.element;return s.parents(\"body\").length||s.appendTo(\"parent\"===i.appendTo?this.element[0].parentNode:i.appendTo),s[0]===this.element[0]||/(fixed|absolute)/.test(s.css(\"position\"))||s.css(\"position\",\"absolute\"),s},_adjustOffsetFromHelper:function(e){\"string\"==typeof e&&(e=e.split(\" \")),t.isArray(e)&&(e={left:+e[0],top:+e[1]||0}),\"left\"in e&&(this.offset.click.left=e.left+this.margins.left),\"right\"in e&&(this.offset.click.left=this.helperProportions.width-e.right+this.margins.left),\"top\"in e&&(this.offset.click.top=e.top+this.margins.top),\"bottom\"in e&&(this.offset.click.top=this.helperProportions.height-e.bottom+this.margins.top)},_getParentOffset:function(){var e=this.offsetParent.offset();return\"absolute\"===this.cssPosition&&this.scrollParent[0]!==document&&t.contains(this.scrollParent[0],this.offsetParent[0])&&(e.left+=this.scrollParent.scrollLeft(),e.top+=this.scrollParent.scrollTop()),(this.offsetParent[0]===document.body||this.offsetParent[0].tagName&&\"html\"===this.offsetParent[0].tagName.toLowerCase()&&t.ui.ie)&&(e={top:0,left:0}),{top:e.top+(parseInt(this.offsetParent.css(\"borderTopWidth\"),10)||0),left:e.left+(parseInt(this.offsetParent.css(\"borderLeftWidth\"),10)||0)}},_getRelativeOffset:function(){if(\"relative\"===this.cssPosition){var t=this.element.position();return{top:t.top-(parseInt(this.helper.css(\"top\"),10)||0)+this.scrollParent.scrollTop(),left:t.left-(parseInt(this.helper.css(\"left\"),10)||0)+this.scrollParent.scrollLeft()}}return{top:0,left:0}},_cacheMargins:function(){this.margins={left:parseInt(this.element.css(\"marginLeft\"),10)||0,top:parseInt(this.element.css(\"marginTop\"),10)||0,right:parseInt(this.element.css(\"marginRight\"),10)||0,bottom:parseInt(this.element.css(\"marginBottom\"),10)||0}},_cacheHelperProportions:function(){this.helperProportions={width:this.helper.outerWidth(),height:this.helper.outerHeight()}},_setContainment:function(){var e,i,s,n=this.options;return n.containment?\"window\"===n.containment?(this.containment=[t(window).scrollLeft()-this.offset.relative.left-this.offset.parent.left,t(window).scrollTop()-this.offset.relative.top-this.offset.parent.top,t(window).scrollLeft()+t(window).width()-this.helperProportions.width-this.margins.left,t(window).scrollTop()+(t(window).height()||document.body.parentNode.scrollHeight)-this.helperProportions.height-this.margins.top],undefined):\"document\"===n.containment?(this.containment=[0,0,t(document).width()-this.helperProportions.width-this.margins.left,(t(document).height()||document.body.parentNode.scrollHeight)-this.helperProportions.height-this.margins.top],undefined):n.containment.constructor===Array?(this.containment=n.containment,undefined):(\"parent\"===n.containment&&(n.containment=this.helper[0].parentNode),i=t(n.containment),s=i[0],s&&(e=\"hidden\"!==i.css(\"overflow\"),this.containment=[(parseInt(i.css(\"borderLeftWidth\"),10)||0)+(parseInt(i.css(\"paddingLeft\"),10)||0),(parseInt(i.css(\"borderTopWidth\"),10)||0)+(parseInt(i.css(\"paddingTop\"),10)||0),(e?Math.max(s.scrollWidth,s.offsetWidth):s.offsetWidth)-(parseInt(i.css(\"borderRightWidth\"),10)||0)-(parseInt(i.css(\"paddingRight\"),10)||0)-this.helperProportions.width-this.margins.left-this.margins.right,(e?Math.max(s.scrollHeight,s.offsetHeight):s.offsetHeight)-(parseInt(i.css(\"borderBottomWidth\"),10)||0)-(parseInt(i.css(\"paddingBottom\"),10)||0)-this.helperProportions.height-this.margins.top-this.margins.bottom],this.relative_container=i),undefined):(this.containment=null,undefined)},_convertPositionTo:function(e,i){i||(i=this.position);var s=\"absolute\"===e?1:-1,n=\"absolute\"!==this.cssPosition||this.scrollParent[0]!==document&&t.contains(this.scrollParent[0],this.offsetParent[0])?this.scrollParent:this.offsetParent;return this.offset.scroll||(this.offset.scroll={top:n.scrollTop(),left:n.scrollLeft()}),{top:i.top+this.offset.relative.top*s+this.offset.parent.top*s-(\"fixed\"===this.cssPosition?-this.scrollParent.scrollTop():this.offset.scroll.top)*s,left:i.left+this.offset.relative.left*s+this.offset.parent.left*s-(\"fixed\"===this.cssPosition?-this.scrollParent.scrollLeft():this.offset.scroll.left)*s}},_generatePosition:function(e){var i,s,n,o,a=this.options,r=\"absolute\"!==this.cssPosition||this.scrollParent[0]!==document&&t.contains(this.scrollParent[0],this.offsetParent[0])?this.scrollParent:this.offsetParent,h=e.pageX,l=e.pageY;return this.offset.scroll||(this.offset.scroll={top:r.scrollTop(),left:r.scrollLeft()}),this.originalPosition&&(this.containment&&(this.relative_container?(s=this.relative_container.offset(),i=[this.containment[0]+s.left,this.containment[1]+s.top,this.containment[2]+s.left,this.containment[3]+s.top]):i=this.containment,e.pageX-this.offset.click.left<i[0]&&(h=i[0]+this.offset.click.left),e.pageY-this.offset.click.top<i[1]&&(l=i[1]+this.offset.click.top),e.pageX-this.offset.click.left>i[2]&&(h=i[2]+this.offset.click.left),e.pageY-this.offset.click.top>i[3]&&(l=i[3]+this.offset.click.top)),a.grid&&(n=a.grid[1]?this.originalPageY+Math.round((l-this.originalPageY)/a.grid[1])*a.grid[1]:this.originalPageY,l=i?n-this.offset.click.top>=i[1]||n-this.offset.click.top>i[3]?n:n-this.offset.click.top>=i[1]?n-a.grid[1]:n+a.grid[1]:n,o=a.grid[0]?this.originalPageX+Math.round((h-this.originalPageX)/a.grid[0])*a.grid[0]:this.originalPageX,h=i?o-this.offset.click.left>=i[0]||o-this.offset.click.left>i[2]?o:o-this.offset.click.left>=i[0]?o-a.grid[0]:o+a.grid[0]:o)),{top:l-this.offset.click.top-this.offset.relative.top-this.offset.parent.top+(\"fixed\"===this.cssPosition?-this.scrollParent.scrollTop():this.offset.scroll.top),left:h-this.offset.click.left-this.offset.relative.left-this.offset.parent.left+(\"fixed\"===this.cssPosition?-this.scrollParent.scrollLeft():this.offset.scroll.left)}},_clear:function(){this.helper.removeClass(\"ui-draggable-dragging\"),this.helper[0]===this.element[0]||this.cancelHelperRemoval||this.helper.remove(),this.helper=null,this.cancelHelperRemoval=!1},_trigger:function(e,i,s){return s=s||this._uiHash(),t.ui.plugin.call(this,e,[i,s]),\"drag\"===e&&(this.positionAbs=this._convertPositionTo(\"absolute\")),t.Widget.prototype._trigger.call(this,e,i,s)},plugins:{},_uiHash:function(){return{helper:this.helper,position:this.position,originalPosition:this.originalPosition,offset:this.positionAbs}}}),t.ui.plugin.add(\"draggable\",\"connectToSortable\",{start:function(e,i){var s=t(this).data(\"ui-draggable\"),n=s.options,o=t.extend({},i,{item:s.element});s.sortables=[],t(n.connectToSortable).each(function(){var i=t.data(this,\"ui-sortable\");i&&!i.options.disabled&&(s.sortables.push({instance:i,shouldRevert:i.options.revert}),i.refreshPositions(),i._trigger(\"activate\",e,o))})},stop:function(e,i){var s=t(this).data(\"ui-draggable\"),n=t.extend({},i,{item:s.element});t.each(s.sortables,function(){this.instance.isOver?(this.instance.isOver=0,s.cancelHelperRemoval=!0,this.instance.cancelHelperRemoval=!1,this.shouldRevert&&(this.instance.options.revert=this.shouldRevert),this.instance._mouseStop(e),this.instance.options.helper=this.instance.options._helper,\"original\"===s.options.helper&&this.instance.currentItem.css({top:\"auto\",left:\"auto\"})):(this.instance.cancelHelperRemoval=!1,this.instance._trigger(\"deactivate\",e,n))})},drag:function(e,i){var s=t(this).data(\"ui-draggable\"),n=this;t.each(s.sortables,function(){var o=!1,a=this;this.instance.positionAbs=s.positionAbs,this.instance.helperProportions=s.helperProportions,this.instance.offset.click=s.offset.click,this.instance._intersectsWith(this.instance.containerCache)&&(o=!0,t.each(s.sortables,function(){return this.instance.positionAbs=s.positionAbs,this.instance.helperProportions=s.helperProportions,this.instance.offset.click=s.offset.click,this!==a&&this.instance._intersectsWith(this.instance.containerCache)&&t.contains(a.instance.element[0],this.instance.element[0])&&(o=!1),o})),o?(this.instance.isOver||(this.instance.isOver=1,this.instance.currentItem=t(n).clone().removeAttr(\"id\").appendTo(this.instance.element).data(\"ui-sortable-item\",!0),this.instance.options._helper=this.instance.options.helper,this.instance.options.helper=function(){return i.helper[0]},e.target=this.instance.currentItem[0],this.instance._mouseCapture(e,!0),this.instance._mouseStart(e,!0,!0),this.instance.offset.click.top=s.offset.click.top,this.instance.offset.click.left=s.offset.click.left,this.instance.offset.parent.left-=s.offset.parent.left-this.instance.offset.parent.left,this.instance.offset.parent.top-=s.offset.parent.top-this.instance.offset.parent.top,s._trigger(\"toSortable\",e),s.dropped=this.instance.element,s.currentItem=s.element,this.instance.fromOutside=s),this.instance.currentItem&&this.instance._mouseDrag(e)):this.instance.isOver&&(this.instance.isOver=0,this.instance.cancelHelperRemoval=!0,this.instance.options.revert=!1,this.instance._trigger(\"out\",e,this.instance._uiHash(this.instance)),this.instance._mouseStop(e,!0),this.instance.options.helper=this.instance.options._helper,this.instance.currentItem.remove(),this.instance.placeholder&&this.instance.placeholder.remove(),s._trigger(\"fromSortable\",e),s.dropped=!1)})}}),t.ui.plugin.add(\"draggable\",\"cursor\",{start:function(){var e=t(\"body\"),i=t(this).data(\"ui-draggable\").options;e.css(\"cursor\")&&(i._cursor=e.css(\"cursor\")),e.css(\"cursor\",i.cursor)},stop:function(){var e=t(this).data(\"ui-draggable\").options;e._cursor&&t(\"body\").css(\"cursor\",e._cursor)}}),t.ui.plugin.add(\"draggable\",\"opacity\",{start:function(e,i){var s=t(i.helper),n=t(this).data(\"ui-draggable\").options;s.css(\"opacity\")&&(n._opacity=s.css(\"opacity\")),s.css(\"opacity\",n.opacity)},stop:function(e,i){var s=t(this).data(\"ui-draggable\").options;s._opacity&&t(i.helper).css(\"opacity\",s._opacity)}}),t.ui.plugin.add(\"draggable\",\"scroll\",{start:function(){var e=t(this).data(\"ui-draggable\");e.scrollParent[0]!==document&&\"HTML\"!==e.scrollParent[0].tagName&&(e.overflowOffset=e.scrollParent.offset())},drag:function(e){var i=t(this).data(\"ui-draggable\"),s=i.options,n=!1;i.scrollParent[0]!==document&&\"HTML\"!==i.scrollParent[0].tagName?(s.axis&&\"x\"===s.axis||(i.overflowOffset.top+i.scrollParent[0].offsetHeight-e.pageY<s.scrollSensitivity?i.scrollParent[0].scrollTop=n=i.scrollParent[0].scrollTop+s.scrollSpeed:e.pageY-i.overflowOffset.top<s.scrollSensitivity&&(i.scrollParent[0].scrollTop=n=i.scrollParent[0].scrollTop-s.scrollSpeed)),s.axis&&\"y\"===s.axis||(i.overflowOffset.left+i.scrollParent[0].offsetWidth-e.pageX<s.scrollSensitivity?i.scrollParent[0].scrollLeft=n=i.scrollParent[0].scrollLeft+s.scrollSpeed:e.pageX-i.overflowOffset.left<s.scrollSensitivity&&(i.scrollParent[0].scrollLeft=n=i.scrollParent[0].scrollLeft-s.scrollSpeed))):(s.axis&&\"x\"===s.axis||(e.pageY-t(document).scrollTop()<s.scrollSensitivity?n=t(document).scrollTop(t(document).scrollTop()-s.scrollSpeed):t(window).height()-(e.pageY-t(document).scrollTop())<s.scrollSensitivity&&(n=t(document).scrollTop(t(document).scrollTop()+s.scrollSpeed))),s.axis&&\"y\"===s.axis||(e.pageX-t(document).scrollLeft()<s.scrollSensitivity?n=t(document).scrollLeft(t(document).scrollLeft()-s.scrollSpeed):t(window).width()-(e.pageX-t(document).scrollLeft())<s.scrollSensitivity&&(n=t(document).scrollLeft(t(document).scrollLeft()+s.scrollSpeed)))),n!==!1&&t.ui.ddmanager&&!s.dropBehaviour&&t.ui.ddmanager.prepareOffsets(i,e)}}),t.ui.plugin.add(\"draggable\",\"snap\",{start:function(){var e=t(this).data(\"ui-draggable\"),i=e.options;e.snapElements=[],t(i.snap.constructor!==String?i.snap.items||\":data(ui-draggable)\":i.snap).each(function(){var i=t(this),s=i.offset();this!==e.element[0]&&e.snapElements.push({item:this,width:i.outerWidth(),height:i.outerHeight(),top:s.top,left:s.left})})},drag:function(e,i){var s,n,o,a,r,h,l,c,u,d,p=t(this).data(\"ui-draggable\"),f=p.options,g=f.snapTolerance,m=i.offset.left,v=m+p.helperProportions.width,_=i.offset.top,b=_+p.helperProportions.height;for(u=p.snapElements.length-1;u>=0;u--)r=p.snapElements[u].left,h=r+p.snapElements[u].width,l=p.snapElements[u].top,c=l+p.snapElements[u].height,r-g>v||m>h+g||l-g>b||_>c+g||!t.contains(p.snapElements[u].item.ownerDocument,p.snapElements[u].item)?(p.snapElements[u].snapping&&p.options.snap.release&&p.options.snap.release.call(p.element,e,t.extend(p._uiHash(),{snapItem:p.snapElements[u].item})),p.snapElements[u].snapping=!1):(\"inner\"!==f.snapMode&&(s=g>=Math.abs(l-b),n=g>=Math.abs(c-_),o=g>=Math.abs(r-v),a=g>=Math.abs(h-m),s&&(i.position.top=p._convertPositionTo(\"relative\",{top:l-p.helperProportions.height,left:0}).top-p.margins.top),n&&(i.position.top=p._convertPositionTo(\"relative\",{top:c,left:0}).top-p.margins.top),o&&(i.position.left=p._convertPositionTo(\"relative\",{top:0,left:r-p.helperProportions.width}).left-p.margins.left),a&&(i.position.left=p._convertPositionTo(\"relative\",{top:0,left:h}).left-p.margins.left)),d=s||n||o||a,\"outer\"!==f.snapMode&&(s=g>=Math.abs(l-_),n=g>=Math.abs(c-b),o=g>=Math.abs(r-m),a=g>=Math.abs(h-v),s&&(i.position.top=p._convertPositionTo(\"relative\",{top:l,left:0}).top-p.margins.top),n&&(i.position.top=p._convertPositionTo(\"relative\",{top:c-p.helperProportions.height,left:0}).top-p.margins.top),o&&(i.position.left=p._convertPositionTo(\"relative\",{top:0,left:r}).left-p.margins.left),a&&(i.position.left=p._convertPositionTo(\"relative\",{top:0,left:h-p.helperProportions.width}).left-p.margins.left)),!p.snapElements[u].snapping&&(s||n||o||a||d)&&p.options.snap.snap&&p.options.snap.snap.call(p.element,e,t.extend(p._uiHash(),{snapItem:p.snapElements[u].item})),p.snapElements[u].snapping=s||n||o||a||d)}}),t.ui.plugin.add(\"draggable\",\"stack\",{start:function(){var e,i=this.data(\"ui-draggable\").options,s=t.makeArray(t(i.stack)).sort(function(e,i){return(parseInt(t(e).css(\"zIndex\"),10)||0)-(parseInt(t(i).css(\"zIndex\"),10)||0)});s.length&&(e=parseInt(t(s[0]).css(\"zIndex\"),10)||0,t(s).each(function(i){t(this).css(\"zIndex\",e+i)}),this.css(\"zIndex\",e+s.length))}}),t.ui.plugin.add(\"draggable\",\"zIndex\",{start:function(e,i){var s=t(i.helper),n=t(this).data(\"ui-draggable\").options;s.css(\"zIndex\")&&(n._zIndex=s.css(\"zIndex\")),s.css(\"zIndex\",n.zIndex)},stop:function(e,i){var s=t(this).data(\"ui-draggable\").options;s._zIndex&&t(i.helper).css(\"zIndex\",s._zIndex)}})}(jQuery),function(t){function e(t,e,i){return t>e&&e+i>t}t.widget(\"ui.droppable\",{version:\"1.10.4\",widgetEventPrefix:\"drop\",options:{accept:\"*\",activeClass:!1,addClasses:!0,greedy:!1,hoverClass:!1,scope:\"default\",tolerance:\"intersect\",activate:null,deactivate:null,drop:null,out:null,over:null},_create:function(){var e,i=this.options,s=i.accept;\n" +
                    "this.isover=!1,this.isout=!0,this.accept=t.isFunction(s)?s:function(t){return t.is(s)},this.proportions=function(){return arguments.length?(e=arguments[0],undefined):e?e:e={width:this.element[0].offsetWidth,height:this.element[0].offsetHeight}},t.ui.ddmanager.droppables[i.scope]=t.ui.ddmanager.droppables[i.scope]||[],t.ui.ddmanager.droppables[i.scope].push(this),i.addClasses&&this.element.addClass(\"ui-droppable\")},_destroy:function(){for(var e=0,i=t.ui.ddmanager.droppables[this.options.scope];i.length>e;e++)i[e]===this&&i.splice(e,1);this.element.removeClass(\"ui-droppable ui-droppable-disabled\")},_setOption:function(e,i){\"accept\"===e&&(this.accept=t.isFunction(i)?i:function(t){return t.is(i)}),t.Widget.prototype._setOption.apply(this,arguments)},_activate:function(e){var i=t.ui.ddmanager.current;this.options.activeClass&&this.element.addClass(this.options.activeClass),i&&this._trigger(\"activate\",e,this.ui(i))},_deactivate:function(e){var i=t.ui.ddmanager.current;this.options.activeClass&&this.element.removeClass(this.options.activeClass),i&&this._trigger(\"deactivate\",e,this.ui(i))},_over:function(e){var i=t.ui.ddmanager.current;i&&(i.currentItem||i.element)[0]!==this.element[0]&&this.accept.call(this.element[0],i.currentItem||i.element)&&(this.options.hoverClass&&this.element.addClass(this.options.hoverClass),this._trigger(\"over\",e,this.ui(i)))},_out:function(e){var i=t.ui.ddmanager.current;i&&(i.currentItem||i.element)[0]!==this.element[0]&&this.accept.call(this.element[0],i.currentItem||i.element)&&(this.options.hoverClass&&this.element.removeClass(this.options.hoverClass),this._trigger(\"out\",e,this.ui(i)))},_drop:function(e,i){var s=i||t.ui.ddmanager.current,n=!1;return s&&(s.currentItem||s.element)[0]!==this.element[0]?(this.element.find(\":data(ui-droppable)\").not(\".ui-draggable-dragging\").each(function(){var e=t.data(this,\"ui-droppable\");return e.options.greedy&&!e.options.disabled&&e.options.scope===s.options.scope&&e.accept.call(e.element[0],s.currentItem||s.element)&&t.ui.intersect(s,t.extend(e,{offset:e.element.offset()}),e.options.tolerance)?(n=!0,!1):undefined}),n?!1:this.accept.call(this.element[0],s.currentItem||s.element)?(this.options.activeClass&&this.element.removeClass(this.options.activeClass),this.options.hoverClass&&this.element.removeClass(this.options.hoverClass),this._trigger(\"drop\",e,this.ui(s)),this.element):!1):!1},ui:function(t){return{draggable:t.currentItem||t.element,helper:t.helper,position:t.position,offset:t.positionAbs}}}),t.ui.intersect=function(t,i,s){if(!i.offset)return!1;var n,o,a=(t.positionAbs||t.position.absolute).left,r=(t.positionAbs||t.position.absolute).top,h=a+t.helperProportions.width,l=r+t.helperProportions.height,c=i.offset.left,u=i.offset.top,d=c+i.proportions().width,p=u+i.proportions().height;switch(s){case\"fit\":return a>=c&&d>=h&&r>=u&&p>=l;case\"intersect\":return a+t.helperProportions.width/2>c&&d>h-t.helperProportions.width/2&&r+t.helperProportions.height/2>u&&p>l-t.helperProportions.height/2;case\"pointer\":return n=(t.positionAbs||t.position.absolute).left+(t.clickOffset||t.offset.click).left,o=(t.positionAbs||t.position.absolute).top+(t.clickOffset||t.offset.click).top,e(o,u,i.proportions().height)&&e(n,c,i.proportions().width);case\"touch\":return(r>=u&&p>=r||l>=u&&p>=l||u>r&&l>p)&&(a>=c&&d>=a||h>=c&&d>=h||c>a&&h>d);default:return!1}},t.ui.ddmanager={current:null,droppables:{\"default\":[]},prepareOffsets:function(e,i){var s,n,o=t.ui.ddmanager.droppables[e.options.scope]||[],a=i?i.type:null,r=(e.currentItem||e.element).find(\":data(ui-droppable)\").addBack();t:for(s=0;o.length>s;s++)if(!(o[s].options.disabled||e&&!o[s].accept.call(o[s].element[0],e.currentItem||e.element))){for(n=0;r.length>n;n++)if(r[n]===o[s].element[0]){o[s].proportions().height=0;continue t}o[s].visible=\"none\"!==o[s].element.css(\"display\"),o[s].visible&&(\"mousedown\"===a&&o[s]._activate.call(o[s],i),o[s].offset=o[s].element.offset(),o[s].proportions({width:o[s].element[0].offsetWidth,height:o[s].element[0].offsetHeight}))}},drop:function(e,i){var s=!1;return t.each((t.ui.ddmanager.droppables[e.options.scope]||[]).slice(),function(){this.options&&(!this.options.disabled&&this.visible&&t.ui.intersect(e,this,this.options.tolerance)&&(s=this._drop.call(this,i)||s),!this.options.disabled&&this.visible&&this.accept.call(this.element[0],e.currentItem||e.element)&&(this.isout=!0,this.isover=!1,this._deactivate.call(this,i)))}),s},dragStart:function(e,i){e.element.parentsUntil(\"body\").bind(\"scroll.droppable\",function(){e.options.refreshPositions||t.ui.ddmanager.prepareOffsets(e,i)})},drag:function(e,i){e.options.refreshPositions&&t.ui.ddmanager.prepareOffsets(e,i),t.each(t.ui.ddmanager.droppables[e.options.scope]||[],function(){if(!this.options.disabled&&!this.greedyChild&&this.visible){var s,n,o,a=t.ui.intersect(e,this,this.options.tolerance),r=!a&&this.isover?\"isout\":a&&!this.isover?\"isover\":null;r&&(this.options.greedy&&(n=this.options.scope,o=this.element.parents(\":data(ui-droppable)\").filter(function(){return t.data(this,\"ui-droppable\").options.scope===n}),o.length&&(s=t.data(o[0],\"ui-droppable\"),s.greedyChild=\"isover\"===r)),s&&\"isover\"===r&&(s.isover=!1,s.isout=!0,s._out.call(s,i)),this[r]=!0,this[\"isout\"===r?\"isover\":\"isout\"]=!1,this[\"isover\"===r?\"_over\":\"_out\"].call(this,i),s&&\"isout\"===r&&(s.isout=!1,s.isover=!0,s._over.call(s,i)))}})},dragStop:function(e,i){e.element.parentsUntil(\"body\").unbind(\"scroll.droppable\"),e.options.refreshPositions||t.ui.ddmanager.prepareOffsets(e,i)}}}(jQuery),function(t){function e(t){return parseInt(t,10)||0}function i(t){return!isNaN(parseInt(t,10))}t.widget(\"ui.resizable\",t.ui.mouse,{version:\"1.10.4\",widgetEventPrefix:\"resize\",options:{alsoResize:!1,animate:!1,animateDuration:\"slow\",animateEasing:\"swing\",aspectRatio:!1,autoHide:!1,containment:!1,ghost:!1,grid:!1,handles:\"e,s,se\",helper:!1,maxHeight:null,maxWidth:null,minHeight:10,minWidth:10,zIndex:90,resize:null,start:null,stop:null},_create:function(){var e,i,s,n,o,a=this,r=this.options;if(this.element.addClass(\"ui-resizable\"),t.extend(this,{_aspectRatio:!!r.aspectRatio,aspectRatio:r.aspectRatio,originalElement:this.element,_proportionallyResizeElements:[],_helper:r.helper||r.ghost||r.animate?r.helper||\"ui-resizable-helper\":null}),this.element[0].nodeName.match(/canvas|textarea|input|select|button|img/i)&&(this.element.wrap(t(\"<div class='ui-wrapper' style='overflow: hidden;'></div>\").css({position:this.element.css(\"position\"),width:this.element.outerWidth(),height:this.element.outerHeight(),top:this.element.css(\"top\"),left:this.element.css(\"left\")})),this.element=this.element.parent().data(\"ui-resizable\",this.element.data(\"ui-resizable\")),this.elementIsWrapper=!0,this.element.css({marginLeft:this.originalElement.css(\"marginLeft\"),marginTop:this.originalElement.css(\"marginTop\"),marginRight:this.originalElement.css(\"marginRight\"),marginBottom:this.originalElement.css(\"marginBottom\")}),this.originalElement.css({marginLeft:0,marginTop:0,marginRight:0,marginBottom:0}),this.originalResizeStyle=this.originalElement.css(\"resize\"),this.originalElement.css(\"resize\",\"none\"),this._proportionallyResizeElements.push(this.originalElement.css({position:\"static\",zoom:1,display:\"block\"})),this.originalElement.css({margin:this.originalElement.css(\"margin\")}),this._proportionallyResize()),this.handles=r.handles||(t(\".ui-resizable-handle\",this.element).length?{n:\".ui-resizable-n\",e:\".ui-resizable-e\",s:\".ui-resizable-s\",w:\".ui-resizable-w\",se:\".ui-resizable-se\",sw:\".ui-resizable-sw\",ne:\".ui-resizable-ne\",nw:\".ui-resizable-nw\"}:\"e,s,se\"),this.handles.constructor===String)for(\"all\"===this.handles&&(this.handles=\"n,e,s,w,se,sw,ne,nw\"),e=this.handles.split(\",\"),this.handles={},i=0;e.length>i;i++)s=t.trim(e[i]),o=\"ui-resizable-\"+s,n=t(\"<div class='ui-resizable-handle \"+o+\"'></div>\"),n.css({zIndex:r.zIndex}),\"se\"===s&&n.addClass(\"ui-icon ui-icon-gripsmall-diagonal-se\"),this.handles[s]=\".ui-resizable-\"+s,this.element.append(n);this._renderAxis=function(e){var i,s,n,o;e=e||this.element;for(i in this.handles)this.handles[i].constructor===String&&(this.handles[i]=t(this.handles[i],this.element).show()),this.elementIsWrapper&&this.originalElement[0].nodeName.match(/textarea|input|select|button/i)&&(s=t(this.handles[i],this.element),o=/sw|ne|nw|se|n|s/.test(i)?s.outerHeight():s.outerWidth(),n=[\"padding\",/ne|nw|n/.test(i)?\"Top\":/se|sw|s/.test(i)?\"Bottom\":/^e$/.test(i)?\"Right\":\"Left\"].join(\"\"),e.css(n,o),this._proportionallyResize()),t(this.handles[i]).length},this._renderAxis(this.element),this._handles=t(\".ui-resizable-handle\",this.element).disableSelection(),this._handles.mouseover(function(){a.resizing||(this.className&&(n=this.className.match(/ui-resizable-(se|sw|ne|nw|n|e|s|w)/i)),a.axis=n&&n[1]?n[1]:\"se\")}),r.autoHide&&(this._handles.hide(),t(this.element).addClass(\"ui-resizable-autohide\").mouseenter(function(){r.disabled||(t(this).removeClass(\"ui-resizable-autohide\"),a._handles.show())}).mouseleave(function(){r.disabled||a.resizing||(t(this).addClass(\"ui-resizable-autohide\"),a._handles.hide())})),this._mouseInit()},_destroy:function(){this._mouseDestroy();var e,i=function(e){t(e).removeClass(\"ui-resizable ui-resizable-disabled ui-resizable-resizing\").removeData(\"resizable\").removeData(\"ui-resizable\").unbind(\".resizable\").find(\".ui-resizable-handle\").remove()};return this.elementIsWrapper&&(i(this.element),e=this.element,this.originalElement.css({position:e.css(\"position\"),width:e.outerWidth(),height:e.outerHeight(),top:e.css(\"top\"),left:e.css(\"left\")}).insertAfter(e),e.remove()),this.originalElement.css(\"resize\",this.originalResizeStyle),i(this.originalElement),this},_mouseCapture:function(e){var i,s,n=!1;for(i in this.handles)s=t(this.handles[i])[0],(s===e.target||t.contains(s,e.target))&&(n=!0);return!this.options.disabled&&n},_mouseStart:function(i){var s,n,o,a=this.options,r=this.element.position(),h=this.element;return this.resizing=!0,/absolute/.test(h.css(\"position\"))?h.css({position:\"absolute\",top:h.css(\"top\"),left:h.css(\"left\")}):h.is(\".ui-draggable\")&&h.css({position:\"absolute\",top:r.top,left:r.left}),this._renderProxy(),s=e(this.helper.css(\"left\")),n=e(this.helper.css(\"top\")),a.containment&&(s+=t(a.containment).scrollLeft()||0,n+=t(a.containment).scrollTop()||0),this.offset=this.helper.offset(),this.position={left:s,top:n},this.size=this._helper?{width:this.helper.width(),height:this.helper.height()}:{width:h.width(),height:h.height()},this.originalSize=this._helper?{width:h.outerWidth(),height:h.outerHeight()}:{width:h.width(),height:h.height()},this.originalPosition={left:s,top:n},this.sizeDiff={width:h.outerWidth()-h.width(),height:h.outerHeight()-h.height()},this.originalMousePosition={left:i.pageX,top:i.pageY},this.aspectRatio=\"number\"==typeof a.aspectRatio?a.aspectRatio:this.originalSize.width/this.originalSize.height||1,o=t(\".ui-resizable-\"+this.axis).css(\"cursor\"),t(\"body\").css(\"cursor\",\"auto\"===o?this.axis+\"-resize\":o),h.addClass(\"ui-resizable-resizing\"),this._propagate(\"start\",i),!0},_mouseDrag:function(e){var i,s=this.helper,n={},o=this.originalMousePosition,a=this.axis,r=this.position.top,h=this.position.left,l=this.size.width,c=this.size.height,u=e.pageX-o.left||0,d=e.pageY-o.top||0,p=this._change[a];return p?(i=p.apply(this,[e,u,d]),this._updateVirtualBoundaries(e.shiftKey),(this._aspectRatio||e.shiftKey)&&(i=this._updateRatio(i,e)),i=this._respectSize(i,e),this._updateCache(i),this._propagate(\"resize\",e),this.position.top!==r&&(n.top=this.position.top+\"px\"),this.position.left!==h&&(n.left=this.position.left+\"px\"),this.size.width!==l&&(n.width=this.size.width+\"px\"),this.size.height!==c&&(n.height=this.size.height+\"px\"),s.css(n),!this._helper&&this._proportionallyResizeElements.length&&this._proportionallyResize(),t.isEmptyObject(n)||this._trigger(\"resize\",e,this.ui()),!1):!1},_mouseStop:function(e){this.resizing=!1;var i,s,n,o,a,r,h,l=this.options,c=this;return this._helper&&(i=this._proportionallyResizeElements,s=i.length&&/textarea/i.test(i[0].nodeName),n=s&&t.ui.hasScroll(i[0],\"left\")?0:c.sizeDiff.height,o=s?0:c.sizeDiff.width,a={width:c.helper.width()-o,height:c.helper.height()-n},r=parseInt(c.element.css(\"left\"),10)+(c.position.left-c.originalPosition.left)||null,h=parseInt(c.element.css(\"top\"),10)+(c.position.top-c.originalPosition.top)||null,l.animate||this.element.css(t.extend(a,{top:h,left:r})),c.helper.height(c.size.height),c.helper.width(c.size.width),this._helper&&!l.animate&&this._proportionallyResize()),t(\"body\").css(\"cursor\",\"auto\"),this.element.removeClass(\"ui-resizable-resizing\"),this._propagate(\"stop\",e),this._helper&&this.helper.remove(),!1},_updateVirtualBoundaries:function(t){var e,s,n,o,a,r=this.options;a={minWidth:i(r.minWidth)?r.minWidth:0,maxWidth:i(r.maxWidth)?r.maxWidth:1/0,minHeight:i(r.minHeight)?r.minHeight:0,maxHeight:i(r.maxHeight)?r.maxHeight:1/0},(this._aspectRatio||t)&&(e=a.minHeight*this.aspectRatio,n=a.minWidth/this.aspectRatio,s=a.maxHeight*this.aspectRatio,o=a.maxWidth/this.aspectRatio,e>a.minWidth&&(a.minWidth=e),n>a.minHeight&&(a.minHeight=n),a.maxWidth>s&&(a.maxWidth=s),a.maxHeight>o&&(a.maxHeight=o)),this._vBoundaries=a},_updateCache:function(t){this.offset=this.helper.offset(),i(t.left)&&(this.position.left=t.left),i(t.top)&&(this.position.top=t.top),i(t.height)&&(this.size.height=t.height),i(t.width)&&(this.size.width=t.width)},_updateRatio:function(t){var e=this.position,s=this.size,n=this.axis;return i(t.height)?t.width=t.height*this.aspectRatio:i(t.width)&&(t.height=t.width/this.aspectRatio),\"sw\"===n&&(t.left=e.left+(s.width-t.width),t.top=null),\"nw\"===n&&(t.top=e.top+(s.height-t.height),t.left=e.left+(s.width-t.width)),t},_respectSize:function(t){var e=this._vBoundaries,s=this.axis,n=i(t.width)&&e.maxWidth&&e.maxWidth<t.width,o=i(t.height)&&e.maxHeight&&e.maxHeight<t.height,a=i(t.width)&&e.minWidth&&e.minWidth>t.width,r=i(t.height)&&e.minHeight&&e.minHeight>t.height,h=this.originalPosition.left+this.originalSize.width,l=this.position.top+this.size.height,c=/sw|nw|w/.test(s),u=/nw|ne|n/.test(s);return a&&(t.width=e.minWidth),r&&(t.height=e.minHeight),n&&(t.width=e.maxWidth),o&&(t.height=e.maxHeight),a&&c&&(t.left=h-e.minWidth),n&&c&&(t.left=h-e.maxWidth),r&&u&&(t.top=l-e.minHeight),o&&u&&(t.top=l-e.maxHeight),t.width||t.height||t.left||!t.top?t.width||t.height||t.top||!t.left||(t.left=null):t.top=null,t},_proportionallyResize:function(){if(this._proportionallyResizeElements.length){var t,e,i,s,n,o=this.helper||this.element;for(t=0;this._proportionallyResizeElements.length>t;t++){if(n=this._proportionallyResizeElements[t],!this.borderDif)for(this.borderDif=[],i=[n.css(\"borderTopWidth\"),n.css(\"borderRightWidth\"),n.css(\"borderBottomWidth\"),n.css(\"borderLeftWidth\")],s=[n.css(\"paddingTop\"),n.css(\"paddingRight\"),n.css(\"paddingBottom\"),n.css(\"paddingLeft\")],e=0;i.length>e;e++)this.borderDif[e]=(parseInt(i[e],10)||0)+(parseInt(s[e],10)||0);n.css({height:o.height()-this.borderDif[0]-this.borderDif[2]||0,width:o.width()-this.borderDif[1]-this.borderDif[3]||0})}}},_renderProxy:function(){var e=this.element,i=this.options;this.elementOffset=e.offset(),this._helper?(this.helper=this.helper||t(\"<div style='overflow:hidden;'></div>\"),this.helper.addClass(this._helper).css({width:this.element.outerWidth()-1,height:this.element.outerHeight()-1,position:\"absolute\",left:this.elementOffset.left+\"px\",top:this.elementOffset.top+\"px\",zIndex:++i.zIndex}),this.helper.appendTo(\"body\").disableSelection()):this.helper=this.element},_change:{e:function(t,e){return{width:this.originalSize.width+e}},w:function(t,e){var i=this.originalSize,s=this.originalPosition;return{left:s.left+e,width:i.width-e}},n:function(t,e,i){var s=this.originalSize,n=this.originalPosition;return{top:n.top+i,height:s.height-i}},s:function(t,e,i){return{height:this.originalSize.height+i}},se:function(e,i,s){return t.extend(this._change.s.apply(this,arguments),this._change.e.apply(this,[e,i,s]))},sw:function(e,i,s){return t.extend(this._change.s.apply(this,arguments),this._change.w.apply(this,[e,i,s]))},ne:function(e,i,s){return t.extend(this._change.n.apply(this,arguments),this._change.e.apply(this,[e,i,s]))},nw:function(e,i,s){return t.extend(this._change.n.apply(this,arguments),this._change.w.apply(this,[e,i,s]))}},_propagate:function(e,i){t.ui.plugin.call(this,e,[i,this.ui()]),\"resize\"!==e&&this._trigger(e,i,this.ui())},plugins:{},ui:function(){return{originalElement:this.originalElement,element:this.element,helper:this.helper,position:this.position,size:this.size,originalSize:this.originalSize,originalPosition:this.originalPosition}}}),t.ui.plugin.add(\"resizable\",\"animate\",{stop:function(e){var i=t(this).data(\"ui-resizable\"),s=i.options,n=i._proportionallyResizeElements,o=n.length&&/textarea/i.test(n[0].nodeName),a=o&&t.ui.hasScroll(n[0],\"left\")?0:i.sizeDiff.height,r=o?0:i.sizeDiff.width,h={width:i.size.width-r,height:i.size.height-a},l=parseInt(i.element.css(\"left\"),10)+(i.position.left-i.originalPosition.left)||null,c=parseInt(i.element.css(\"top\"),10)+(i.position.top-i.originalPosition.top)||null;i.element.animate(t.extend(h,c&&l?{top:c,left:l}:{}),{duration:s.animateDuration,easing:s.animateEasing,step:function(){var s={width:parseInt(i.element.css(\"width\"),10),height:parseInt(i.element.css(\"height\"),10),top:parseInt(i.element.css(\"top\"),10),left:parseInt(i.element.css(\"left\"),10)};n&&n.length&&t(n[0]).css({width:s.width,height:s.height}),i._updateCache(s),i._propagate(\"resize\",e)}})}}),t.ui.plugin.add(\"resizable\",\"containment\",{start:function(){var i,s,n,o,a,r,h,l=t(this).data(\"ui-resizable\"),c=l.options,u=l.element,d=c.containment,p=d instanceof t?d.get(0):/parent/.test(d)?u.parent().get(0):d;p&&(l.containerElement=t(p),/document/.test(d)||d===document?(l.containerOffset={left:0,top:0},l.containerPosition={left:0,top:0},l.parentData={element:t(document),left:0,top:0,width:t(document).width(),height:t(document).height()||document.body.parentNode.scrollHeight}):(i=t(p),s=[],t([\"Top\",\"Right\",\"Left\",\"Bottom\"]).each(function(t,n){s[t]=e(i.css(\"padding\"+n))}),l.containerOffset=i.offset(),l.containerPosition=i.position(),l.containerSize={height:i.innerHeight()-s[3],width:i.innerWidth()-s[1]},n=l.containerOffset,o=l.containerSize.height,a=l.containerSize.width,r=t.ui.hasScroll(p,\"left\")?p.scrollWidth:a,h=t.ui.hasScroll(p)?p.scrollHeight:o,l.parentData={element:p,left:n.left,top:n.top,width:r,height:h}))},resize:function(e){var i,s,n,o,a=t(this).data(\"ui-resizable\"),r=a.options,h=a.containerOffset,l=a.position,c=a._aspectRatio||e.shiftKey,u={top:0,left:0},d=a.containerElement;d[0]!==document&&/static/.test(d.css(\"position\"))&&(u=h),l.left<(a._helper?h.left:0)&&(a.size.width=a.size.width+(a._helper?a.position.left-h.left:a.position.left-u.left),c&&(a.size.height=a.size.width/a.aspectRatio),a.position.left=r.helper?h.left:0),l.top<(a._helper?h.top:0)&&(a.size.height=a.size.height+(a._helper?a.position.top-h.top:a.position.top),c&&(a.size.width=a.size.height*a.aspectRatio),a.position.top=a._helper?h.top:0),a.offset.left=a.parentData.left+a.position.left,a.offset.top=a.parentData.top+a.position.top,i=Math.abs((a._helper?a.offset.left-u.left:a.offset.left-u.left)+a.sizeDiff.width),s=Math.abs((a._helper?a.offset.top-u.top:a.offset.top-h.top)+a.sizeDiff.height),n=a.containerElement.get(0)===a.element.parent().get(0),o=/relative|absolute/.test(a.containerElement.css(\"position\")),n&&o&&(i-=Math.abs(a.parentData.left)),i+a.size.width>=a.parentData.width&&(a.size.width=a.parentData.width-i,c&&(a.size.height=a.size.width/a.aspectRatio)),s+a.size.height>=a.parentData.height&&(a.size.height=a.parentData.height-s,c&&(a.size.width=a.size.height*a.aspectRatio))},stop:function(){var e=t(this).data(\"ui-resizable\"),i=e.options,s=e.containerOffset,n=e.containerPosition,o=e.containerElement,a=t(e.helper),r=a.offset(),h=a.outerWidth()-e.sizeDiff.width,l=a.outerHeight()-e.sizeDiff.height;e._helper&&!i.animate&&/relative/.test(o.css(\"position\"))&&t(this).css({left:r.left-n.left-s.left,width:h,height:l}),e._helper&&!i.animate&&/static/.test(o.css(\"position\"))&&t(this).css({left:r.left-n.left-s.left,width:h,height:l})}}),t.ui.plugin.add(\"resizable\",\"alsoResize\",{start:function(){var e=t(this).data(\"ui-resizable\"),i=e.options,s=function(e){t(e).each(function(){var e=t(this);e.data(\"ui-resizable-alsoresize\",{width:parseInt(e.width(),10),height:parseInt(e.height(),10),left:parseInt(e.css(\"left\"),10),top:parseInt(e.css(\"top\"),10)})})};\"object\"!=typeof i.alsoResize||i.alsoResize.parentNode?s(i.alsoResize):i.alsoResize.length?(i.alsoResize=i.alsoResize[0],s(i.alsoResize)):t.each(i.alsoResize,function(t){s(t)})},resize:function(e,i){var s=t(this).data(\"ui-resizable\"),n=s.options,o=s.originalSize,a=s.originalPosition,r={height:s.size.height-o.height||0,width:s.size.width-o.width||0,top:s.position.top-a.top||0,left:s.position.left-a.left||0},h=function(e,s){t(e).each(function(){var e=t(this),n=t(this).data(\"ui-resizable-alsoresize\"),o={},a=s&&s.length?s:e.parents(i.originalElement[0]).length?[\"width\",\"height\"]:[\"width\",\"height\",\"top\",\"left\"];t.each(a,function(t,e){var i=(n[e]||0)+(r[e]||0);i&&i>=0&&(o[e]=i||null)}),e.css(o)})};\"object\"!=typeof n.alsoResize||n.alsoResize.nodeType?h(n.alsoResize):t.each(n.alsoResize,function(t,e){h(t,e)})},stop:function(){t(this).removeData(\"resizable-alsoresize\")}}),t.ui.plugin.add(\"resizable\",\"ghost\",{start:function(){var e=t(this).data(\"ui-resizable\"),i=e.options,s=e.size;e.ghost=e.originalElement.clone(),e.ghost.css({opacity:.25,display:\"block\",position:\"relative\",height:s.height,width:s.width,margin:0,left:0,top:0}).addClass(\"ui-resizable-ghost\").addClass(\"string\"==typeof i.ghost?i.ghost:\"\"),e.ghost.appendTo(e.helper)},resize:function(){var e=t(this).data(\"ui-resizable\");e.ghost&&e.ghost.css({position:\"relative\",height:e.size.height,width:e.size.width})},stop:function(){var e=t(this).data(\"ui-resizable\");e.ghost&&e.helper&&e.helper.get(0).removeChild(e.ghost.get(0))}}),t.ui.plugin.add(\"resizable\",\"grid\",{resize:function(){var e=t(this).data(\"ui-resizable\"),i=e.options,s=e.size,n=e.originalSize,o=e.originalPosition,a=e.axis,r=\"number\"==typeof i.grid?[i.grid,i.grid]:i.grid,h=r[0]||1,l=r[1]||1,c=Math.round((s.width-n.width)/h)*h,u=Math.round((s.height-n.height)/l)*l,d=n.width+c,p=n.height+u,f=i.maxWidth&&d>i.maxWidth,g=i.maxHeight&&p>i.maxHeight,m=i.minWidth&&i.minWidth>d,v=i.minHeight&&i.minHeight>p;i.grid=r,m&&(d+=h),v&&(p+=l),f&&(d-=h),g&&(p-=l),/^(se|s|e)$/.test(a)?(e.size.width=d,e.size.height=p):/^(ne)$/.test(a)?(e.size.width=d,e.size.height=p,e.position.top=o.top-u):/^(sw)$/.test(a)?(e.size.width=d,e.size.height=p,e.position.left=o.left-c):(p-l>0?(e.size.height=p,e.position.top=o.top-u):(e.size.height=l,e.position.top=o.top+n.height-l),d-h>0?(e.size.width=d,e.position.left=o.left-c):(e.size.width=h,e.position.left=o.left+n.width-h))}})}(jQuery),function(t){t.widget(\"ui.selectable\",t.ui.mouse,{version:\"1.10.4\",options:{appendTo:\"body\",autoRefresh:!0,distance:0,filter:\"*\",tolerance:\"touch\",selected:null,selecting:null,start:null,stop:null,unselected:null,unselecting:null},_create:function(){var e,i=this;this.element.addClass(\"ui-selectable\"),this.dragged=!1,this.refresh=function(){e=t(i.options.filter,i.element[0]),e.addClass(\"ui-selectee\"),e.each(function(){var e=t(this),i=e.offset();t.data(this,\"selectable-item\",{element:this,$element:e,left:i.left,top:i.top,right:i.left+e.outerWidth(),bottom:i.top+e.outerHeight(),startselected:!1,selected:e.hasClass(\"ui-selected\"),selecting:e.hasClass(\"ui-selecting\"),unselecting:e.hasClass(\"ui-unselecting\")})})},this.refresh(),this.selectees=e.addClass(\"ui-selectee\"),this._mouseInit(),this.helper=t(\"<div class='ui-selectable-helper'></div>\")},_destroy:function(){this.selectees.removeClass(\"ui-selectee\").removeData(\"selectable-item\"),this.element.removeClass(\"ui-selectable ui-selectable-disabled\"),this._mouseDestroy()},_mouseStart:function(e){var i=this,s=this.options;this.opos=[e.pageX,e.pageY],this.options.disabled||(this.selectees=t(s.filter,this.element[0]),this._trigger(\"start\",e),t(s.appendTo).append(this.helper),this.helper.css({left:e.pageX,top:e.pageY,width:0,height:0}),s.autoRefresh&&this.refresh(),this.selectees.filter(\".ui-selected\").each(function(){var s=t.data(this,\"selectable-item\");s.startselected=!0,e.metaKey||e.ctrlKey||(s.$element.removeClass(\"ui-selected\"),s.selected=!1,s.$element.addClass(\"ui-unselecting\"),s.unselecting=!0,i._trigger(\"unselecting\",e,{unselecting:s.element}))}),t(e.target).parents().addBack().each(function(){var s,n=t.data(this,\"selectable-item\");return n?(s=!e.metaKey&&!e.ctrlKey||!n.$element.hasClass(\"ui-selected\"),n.$element.removeClass(s?\"ui-unselecting\":\"ui-selected\").addClass(s?\"ui-selecting\":\"ui-unselecting\"),n.unselecting=!s,n.selecting=s,n.selected=s,s?i._trigger(\"selecting\",e,{selecting:n.element}):i._trigger(\"unselecting\",e,{unselecting:n.element}),!1):undefined}))},_mouseDrag:function(e){if(this.dragged=!0,!this.options.disabled){var i,s=this,n=this.options,o=this.opos[0],a=this.opos[1],r=e.pageX,h=e.pageY;return o>r&&(i=r,r=o,o=i),a>h&&(i=h,h=a,a=i),this.helper.css({left:o,top:a,width:r-o,height:h-a}),this.selectees.each(function(){var i=t.data(this,\"selectable-item\"),l=!1;i&&i.element!==s.element[0]&&(\"touch\"===n.tolerance?l=!(i.left>r||o>i.right||i.top>h||a>i.bottom):\"fit\"===n.tolerance&&(l=i.left>o&&r>i.right&&i.top>a&&h>i.bottom),l?(i.selected&&(i.$element.removeClass(\"ui-selected\"),i.selected=!1),i.unselecting&&(i.$element.removeClass(\"ui-unselecting\"),i.unselecting=!1),i.selecting||(i.$element.addClass(\"ui-selecting\"),i.selecting=!0,s._trigger(\"selecting\",e,{selecting:i.element}))):(i.selecting&&((e.metaKey||e.ctrlKey)&&i.startselected?(i.$element.removeClass(\"ui-selecting\"),i.selecting=!1,i.$element.addClass(\"ui-selected\"),i.selected=!0):(i.$element.removeClass(\"ui-selecting\"),i.selecting=!1,i.startselected&&(i.$element.addClass(\"ui-unselecting\"),i.unselecting=!0),s._trigger(\"unselecting\",e,{unselecting:i.element}))),i.selected&&(e.metaKey||e.ctrlKey||i.startselected||(i.$element.removeClass(\"ui-selected\"),i.selected=!1,i.$element.addClass(\"ui-unselecting\"),i.unselecting=!0,s._trigger(\"unselecting\",e,{unselecting:i.element})))))}),!1}},_mouseStop:function(e){var i=this;return this.dragged=!1,t(\".ui-unselecting\",this.element[0]).each(function(){var s=t.data(this,\"selectable-item\");");
            bufferedWriter.write("s.$element.removeClass(\"ui-unselecting\"),s.unselecting=!1,s.startselected=!1,i._trigger(\"unselected\",e,{unselected:s.element})}),t(\".ui-selecting\",this.element[0]).each(function(){var s=t.data(this,\"selectable-item\");s.$element.removeClass(\"ui-selecting\").addClass(\"ui-selected\"),s.selecting=!1,s.selected=!0,s.startselected=!0,i._trigger(\"selected\",e,{selected:s.element})}),this._trigger(\"stop\",e),this.helper.remove(),!1}})}(jQuery),function(t){function e(t,e,i){return t>e&&e+i>t}function i(t){return/left|right/.test(t.css(\"float\"))||/inline|table-cell/.test(t.css(\"display\"))}t.widget(\"ui.sortable\",t.ui.mouse,{version:\"1.10.4\",widgetEventPrefix:\"sort\",ready:!1,options:{appendTo:\"parent\",axis:!1,connectWith:!1,containment:!1,cursor:\"auto\",cursorAt:!1,dropOnEmpty:!0,forcePlaceholderSize:!1,forceHelperSize:!1,grid:!1,handle:!1,helper:\"original\",items:\"> *\",opacity:!1,placeholder:!1,revert:!1,scroll:!0,scrollSensitivity:20,scrollSpeed:20,scope:\"default\",tolerance:\"intersect\",zIndex:1e3,activate:null,beforeStop:null,change:null,deactivate:null,out:null,over:null,receive:null,remove:null,sort:null,start:null,stop:null,update:null},_create:function(){var t=this.options;this.containerCache={},this.element.addClass(\"ui-sortable\"),this.refresh(),this.floating=this.items.length?\"x\"===t.axis||i(this.items[0].item):!1,this.offset=this.element.offset(),this._mouseInit(),this.ready=!0},_destroy:function(){this.element.removeClass(\"ui-sortable ui-sortable-disabled\"),this._mouseDestroy();for(var t=this.items.length-1;t>=0;t--)this.items[t].item.removeData(this.widgetName+\"-item\");return this},_setOption:function(e,i){\"disabled\"===e?(this.options[e]=i,this.widget().toggleClass(\"ui-sortable-disabled\",!!i)):t.Widget.prototype._setOption.apply(this,arguments)},_mouseCapture:function(e,i){var s=null,n=!1,o=this;return this.reverting?!1:this.options.disabled||\"static\"===this.options.type?!1:(this._refreshItems(e),t(e.target).parents().each(function(){return t.data(this,o.widgetName+\"-item\")===o?(s=t(this),!1):undefined}),t.data(e.target,o.widgetName+\"-item\")===o&&(s=t(e.target)),s?!this.options.handle||i||(t(this.options.handle,s).find(\"*\").addBack().each(function(){this===e.target&&(n=!0)}),n)?(this.currentItem=s,this._removeCurrentsFromItems(),!0):!1:!1)},_mouseStart:function(e,i,s){var n,o,a=this.options;if(this.currentContainer=this,this.refreshPositions(),this.helper=this._createHelper(e),this._cacheHelperProportions(),this._cacheMargins(),this.scrollParent=this.helper.scrollParent(),this.offset=this.currentItem.offset(),this.offset={top:this.offset.top-this.margins.top,left:this.offset.left-this.margins.left},t.extend(this.offset,{click:{left:e.pageX-this.offset.left,top:e.pageY-this.offset.top},parent:this._getParentOffset(),relative:this._getRelativeOffset()}),this.helper.css(\"position\",\"absolute\"),this.cssPosition=this.helper.css(\"position\"),this.originalPosition=this._generatePosition(e),this.originalPageX=e.pageX,this.originalPageY=e.pageY,a.cursorAt&&this._adjustOffsetFromHelper(a.cursorAt),this.domPosition={prev:this.currentItem.prev()[0],parent:this.currentItem.parent()[0]},this.helper[0]!==this.currentItem[0]&&this.currentItem.hide(),this._createPlaceholder(),a.containment&&this._setContainment(),a.cursor&&\"auto\"!==a.cursor&&(o=this.document.find(\"body\"),this.storedCursor=o.css(\"cursor\"),o.css(\"cursor\",a.cursor),this.storedStylesheet=t(\"<style>*{ cursor: \"+a.cursor+\" !important; }</style>\").appendTo(o)),a.opacity&&(this.helper.css(\"opacity\")&&(this._storedOpacity=this.helper.css(\"opacity\")),this.helper.css(\"opacity\",a.opacity)),a.zIndex&&(this.helper.css(\"zIndex\")&&(this._storedZIndex=this.helper.css(\"zIndex\")),this.helper.css(\"zIndex\",a.zIndex)),this.scrollParent[0]!==document&&\"HTML\"!==this.scrollParent[0].tagName&&(this.overflowOffset=this.scrollParent.offset()),this._trigger(\"start\",e,this._uiHash()),this._preserveHelperProportions||this._cacheHelperProportions(),!s)for(n=this.containers.length-1;n>=0;n--)this.containers[n]._trigger(\"activate\",e,this._uiHash(this));return t.ui.ddmanager&&(t.ui.ddmanager.current=this),t.ui.ddmanager&&!a.dropBehaviour&&t.ui.ddmanager.prepareOffsets(this,e),this.dragging=!0,this.helper.addClass(\"ui-sortable-helper\"),this._mouseDrag(e),!0},_mouseDrag:function(e){var i,s,n,o,a=this.options,r=!1;for(this.position=this._generatePosition(e),this.positionAbs=this._convertPositionTo(\"absolute\"),this.lastPositionAbs||(this.lastPositionAbs=this.positionAbs),this.options.scroll&&(this.scrollParent[0]!==document&&\"HTML\"!==this.scrollParent[0].tagName?(this.overflowOffset.top+this.scrollParent[0].offsetHeight-e.pageY<a.scrollSensitivity?this.scrollParent[0].scrollTop=r=this.scrollParent[0].scrollTop+a.scrollSpeed:e.pageY-this.overflowOffset.top<a.scrollSensitivity&&(this.scrollParent[0].scrollTop=r=this.scrollParent[0].scrollTop-a.scrollSpeed),this.overflowOffset.left+this.scrollParent[0].offsetWidth-e.pageX<a.scrollSensitivity?this.scrollParent[0].scrollLeft=r=this.scrollParent[0].scrollLeft+a.scrollSpeed:e.pageX-this.overflowOffset.left<a.scrollSensitivity&&(this.scrollParent[0].scrollLeft=r=this.scrollParent[0].scrollLeft-a.scrollSpeed)):(e.pageY-t(document).scrollTop()<a.scrollSensitivity?r=t(document).scrollTop(t(document).scrollTop()-a.scrollSpeed):t(window).height()-(e.pageY-t(document).scrollTop())<a.scrollSensitivity&&(r=t(document).scrollTop(t(document).scrollTop()+a.scrollSpeed)),e.pageX-t(document).scrollLeft()<a.scrollSensitivity?r=t(document).scrollLeft(t(document).scrollLeft()-a.scrollSpeed):t(window).width()-(e.pageX-t(document).scrollLeft())<a.scrollSensitivity&&(r=t(document).scrollLeft(t(document).scrollLeft()+a.scrollSpeed))),r!==!1&&t.ui.ddmanager&&!a.dropBehaviour&&t.ui.ddmanager.prepareOffsets(this,e)),this.positionAbs=this._convertPositionTo(\"absolute\"),this.options.axis&&\"y\"===this.options.axis||(this.helper[0].style.left=this.position.left+\"px\"),this.options.axis&&\"x\"===this.options.axis||(this.helper[0].style.top=this.position.top+\"px\"),i=this.items.length-1;i>=0;i--)if(s=this.items[i],n=s.item[0],o=this._intersectsWithPointer(s),o&&s.instance===this.currentContainer&&n!==this.currentItem[0]&&this.placeholder[1===o?\"next\":\"prev\"]()[0]!==n&&!t.contains(this.placeholder[0],n)&&(\"semi-dynamic\"===this.options.type?!t.contains(this.element[0],n):!0)){if(this.direction=1===o?\"down\":\"up\",\"pointer\"!==this.options.tolerance&&!this._intersectsWithSides(s))break;\n" +
                    "this._rearrange(e,s),this._trigger(\"change\",e,this._uiHash());break}return this._contactContainers(e),t.ui.ddmanager&&t.ui.ddmanager.drag(this,e),this._trigger(\"sort\",e,this._uiHash()),this.lastPositionAbs=this.positionAbs,!1},_mouseStop:function(e,i){if(e){if(t.ui.ddmanager&&!this.options.dropBehaviour&&t.ui.ddmanager.drop(this,e),this.options.revert){var s=this,n=this.placeholder.offset(),o=this.options.axis,a={};o&&\"x\"!==o||(a.left=n.left-this.offset.parent.left-this.margins.left+(this.offsetParent[0]===document.body?0:this.offsetParent[0].scrollLeft)),o&&\"y\"!==o||(a.top=n.top-this.offset.parent.top-this.margins.top+(this.offsetParent[0]===document.body?0:this.offsetParent[0].scrollTop)),this.reverting=!0,t(this.helper).animate(a,parseInt(this.options.revert,10)||500,function(){s._clear(e)})}else this._clear(e,i);return!1}},cancel:function(){if(this.dragging){this._mouseUp({target:null}),\"original\"===this.options.helper?this.currentItem.css(this._storedCSS).removeClass(\"ui-sortable-helper\"):this.currentItem.show();for(var e=this.containers.length-1;e>=0;e--)this.containers[e]._trigger(\"deactivate\",null,this._uiHash(this)),this.containers[e].containerCache.over&&(this.containers[e]._trigger(\"out\",null,this._uiHash(this)),this.containers[e].containerCache.over=0)}return this.placeholder&&(this.placeholder[0].parentNode&&this.placeholder[0].parentNode.removeChild(this.placeholder[0]),\"original\"!==this.options.helper&&this.helper&&this.helper[0].parentNode&&this.helper.remove(),t.extend(this,{helper:null,dragging:!1,reverting:!1,_noFinalSort:null}),this.domPosition.prev?t(this.domPosition.prev).after(this.currentItem):t(this.domPosition.parent).prepend(this.currentItem)),this},serialize:function(e){var i=this._getItemsAsjQuery(e&&e.connected),s=[];return e=e||{},t(i).each(function(){var i=(t(e.item||this).attr(e.attribute||\"id\")||\"\").match(e.expression||/(.+)[\\-=_](.+)/);i&&s.push((e.key||i[1]+\"[]\")+\"=\"+(e.key&&e.expression?i[1]:i[2]))}),!s.length&&e.key&&s.push(e.key+\"=\"),s.join(\"&\")},toArray:function(e){var i=this._getItemsAsjQuery(e&&e.connected),s=[];return e=e||{},i.each(function(){s.push(t(e.item||this).attr(e.attribute||\"id\")||\"\")}),s},_intersectsWith:function(t){var e=this.positionAbs.left,i=e+this.helperProportions.width,s=this.positionAbs.top,n=s+this.helperProportions.height,o=t.left,a=o+t.width,r=t.top,h=r+t.height,l=this.offset.click.top,c=this.offset.click.left,u=\"x\"===this.options.axis||s+l>r&&h>s+l,d=\"y\"===this.options.axis||e+c>o&&a>e+c,p=u&&d;return\"pointer\"===this.options.tolerance||this.options.forcePointerForContainers||\"pointer\"!==this.options.tolerance&&this.helperProportions[this.floating?\"width\":\"height\"]>t[this.floating?\"width\":\"height\"]?p:e+this.helperProportions.width/2>o&&a>i-this.helperProportions.width/2&&s+this.helperProportions.height/2>r&&h>n-this.helperProportions.height/2},_intersectsWithPointer:function(t){var i=\"x\"===this.options.axis||e(this.positionAbs.top+this.offset.click.top,t.top,t.height),s=\"y\"===this.options.axis||e(this.positionAbs.left+this.offset.click.left,t.left,t.width),n=i&&s,o=this._getDragVerticalDirection(),a=this._getDragHorizontalDirection();return n?this.floating?a&&\"right\"===a||\"down\"===o?2:1:o&&(\"down\"===o?2:1):!1},_intersectsWithSides:function(t){var i=e(this.positionAbs.top+this.offset.click.top,t.top+t.height/2,t.height),s=e(this.positionAbs.left+this.offset.click.left,t.left+t.width/2,t.width),n=this._getDragVerticalDirection(),o=this._getDragHorizontalDirection();return this.floating&&o?\"right\"===o&&s||\"left\"===o&&!s:n&&(\"down\"===n&&i||\"up\"===n&&!i)},_getDragVerticalDirection:function(){var t=this.positionAbs.top-this.lastPositionAbs.top;return 0!==t&&(t>0?\"down\":\"up\")},_getDragHorizontalDirection:function(){var t=this.positionAbs.left-this.lastPositionAbs.left;return 0!==t&&(t>0?\"right\":\"left\")},refresh:function(t){return this._refreshItems(t),this.refreshPositions(),this},_connectWith:function(){var t=this.options;return t.connectWith.constructor===String?[t.connectWith]:t.connectWith},_getItemsAsjQuery:function(e){function i(){r.push(this)}var s,n,o,a,r=[],h=[],l=this._connectWith();if(l&&e)for(s=l.length-1;s>=0;s--)for(o=t(l[s]),n=o.length-1;n>=0;n--)a=t.data(o[n],this.widgetFullName),a&&a!==this&&!a.options.disabled&&h.push([t.isFunction(a.options.items)?a.options.items.call(a.element):t(a.options.items,a.element).not(\".ui-sortable-helper\").not(\".ui-sortable-placeholder\"),a]);for(h.push([t.isFunction(this.options.items)?this.options.items.call(this.element,null,{options:this.options,item:this.currentItem}):t(this.options.items,this.element).not(\".ui-sortable-helper\").not(\".ui-sortable-placeholder\"),this]),s=h.length-1;s>=0;s--)h[s][0].each(i);return t(r)},_removeCurrentsFromItems:function(){var e=this.currentItem.find(\":data(\"+this.widgetName+\"-item)\");this.items=t.grep(this.items,function(t){for(var i=0;e.length>i;i++)if(e[i]===t.item[0])return!1;return!0})},_refreshItems:function(e){this.items=[],this.containers=[this];var i,s,n,o,a,r,h,l,c=this.items,u=[[t.isFunction(this.options.items)?this.options.items.call(this.element[0],e,{item:this.currentItem}):t(this.options.items,this.element),this]],d=this._connectWith();if(d&&this.ready)for(i=d.length-1;i>=0;i--)for(n=t(d[i]),s=n.length-1;s>=0;s--)o=t.data(n[s],this.widgetFullName),o&&o!==this&&!o.options.disabled&&(u.push([t.isFunction(o.options.items)?o.options.items.call(o.element[0],e,{item:this.currentItem}):t(o.options.items,o.element),o]),this.containers.push(o));for(i=u.length-1;i>=0;i--)for(a=u[i][1],r=u[i][0],s=0,l=r.length;l>s;s++)h=t(r[s]),h.data(this.widgetName+\"-item\",a),c.push({item:h,instance:a,width:0,height:0,left:0,top:0})},refreshPositions:function(e){this.offsetParent&&this.helper&&(this.offset.parent=this._getParentOffset());var i,s,n,o;for(i=this.items.length-1;i>=0;i--)s=this.items[i],s.instance!==this.currentContainer&&this.currentContainer&&s.item[0]!==this.currentItem[0]||(n=this.options.toleranceElement?t(this.options.toleranceElement,s.item):s.item,e||(s.width=n.outerWidth(),s.height=n.outerHeight()),o=n.offset(),s.left=o.left,s.top=o.top);if(this.options.custom&&this.options.custom.refreshContainers)this.options.custom.refreshContainers.call(this);else for(i=this.containers.length-1;i>=0;i--)o=this.containers[i].element.offset(),this.containers[i].containerCache.left=o.left,this.containers[i].containerCache.top=o.top,this.containers[i].containerCache.width=this.containers[i].element.outerWidth(),this.containers[i].containerCache.height=this.containers[i].element.outerHeight();return this},_createPlaceholder:function(e){e=e||this;var i,s=e.options;s.placeholder&&s.placeholder.constructor!==String||(i=s.placeholder,s.placeholder={element:function(){var s=e.currentItem[0].nodeName.toLowerCase(),n=t(\"<\"+s+\">\",e.document[0]).addClass(i||e.currentItem[0].className+\" ui-sortable-placeholder\").removeClass(\"ui-sortable-helper\");return\"tr\"===s?e.currentItem.children().each(function(){t(\"<td>&#160;</td>\",e.document[0]).attr(\"colspan\",t(this).attr(\"colspan\")||1).appendTo(n)}):\"img\"===s&&n.attr(\"src\",e.currentItem.attr(\"src\")),i||n.css(\"visibility\",\"hidden\"),n},update:function(t,n){(!i||s.forcePlaceholderSize)&&(n.height()||n.height(e.currentItem.innerHeight()-parseInt(e.currentItem.css(\"paddingTop\")||0,10)-parseInt(e.currentItem.css(\"paddingBottom\")||0,10)),n.width()||n.width(e.currentItem.innerWidth()-parseInt(e.currentItem.css(\"paddingLeft\")||0,10)-parseInt(e.currentItem.css(\"paddingRight\")||0,10)))}}),e.placeholder=t(s.placeholder.element.call(e.element,e.currentItem)),e.currentItem.after(e.placeholder),s.placeholder.update(e,e.placeholder)},_contactContainers:function(s){var n,o,a,r,h,l,c,u,d,p,f=null,g=null;for(n=this.containers.length-1;n>=0;n--)if(!t.contains(this.currentItem[0],this.containers[n].element[0]))if(this._intersectsWith(this.containers[n].containerCache)){if(f&&t.contains(this.containers[n].element[0],f.element[0]))continue;f=this.containers[n],g=n}else this.containers[n].containerCache.over&&(this.containers[n]._trigger(\"out\",s,this._uiHash(this)),this.containers[n].containerCache.over=0);if(f)if(1===this.containers.length)this.containers[g].containerCache.over||(this.containers[g]._trigger(\"over\",s,this._uiHash(this)),this.containers[g].containerCache.over=1);else{for(a=1e4,r=null,p=f.floating||i(this.currentItem),h=p?\"left\":\"top\",l=p?\"width\":\"height\",c=this.positionAbs[h]+this.offset.click[h],o=this.items.length-1;o>=0;o--)t.contains(this.containers[g].element[0],this.items[o].item[0])&&this.items[o].item[0]!==this.currentItem[0]&&(!p||e(this.positionAbs.top+this.offset.click.top,this.items[o].top,this.items[o].height))&&(u=this.items[o].item.offset()[h],d=!1,Math.abs(u-c)>Math.abs(u+this.items[o][l]-c)&&(d=!0,u+=this.items[o][l]),a>Math.abs(u-c)&&(a=Math.abs(u-c),r=this.items[o],this.direction=d?\"up\":\"down\"));if(!r&&!this.options.dropOnEmpty)return;if(this.currentContainer===this.containers[g])return;r?this._rearrange(s,r,null,!0):this._rearrange(s,null,this.containers[g].element,!0),this._trigger(\"change\",s,this._uiHash()),this.containers[g]._trigger(\"change\",s,this._uiHash(this)),this.currentContainer=this.containers[g],this.options.placeholder.update(this.currentContainer,this.placeholder),this.containers[g]._trigger(\"over\",s,this._uiHash(this)),this.containers[g].containerCache.over=1}},_createHelper:function(e){var i=this.options,s=t.isFunction(i.helper)?t(i.helper.apply(this.element[0],[e,this.currentItem])):\"clone\"===i.helper?this.currentItem.clone():this.currentItem;return s.parents(\"body\").length||t(\"parent\"!==i.appendTo?i.appendTo:this.currentItem[0].parentNode)[0].appendChild(s[0]),s[0]===this.currentItem[0]&&(this._storedCSS={width:this.currentItem[0].style.width,height:this.currentItem[0].style.height,position:this.currentItem.css(\"position\"),top:this.currentItem.css(\"top\"),left:this.currentItem.css(\"left\")}),(!s[0].style.width||i.forceHelperSize)&&s.width(this.currentItem.width()),(!s[0].style.height||i.forceHelperSize)&&s.height(this.currentItem.height()),s},_adjustOffsetFromHelper:function(e){\"string\"==typeof e&&(e=e.split(\" \")),t.isArray(e)&&(e={left:+e[0],top:+e[1]||0}),\"left\"in e&&(this.offset.click.left=e.left+this.margins.left),\"right\"in e&&(this.offset.click.left=this.helperProportions.width-e.right+this.margins.left),\"top\"in e&&(this.offset.click.top=e.top+this.margins.top),\"bottom\"in e&&(this.offset.click.top=this.helperProportions.height-e.bottom+this.margins.top)},_getParentOffset:function(){this.offsetParent=this.helper.offsetParent();var e=this.offsetParent.offset();return\"absolute\"===this.cssPosition&&this.scrollParent[0]!==document&&t.contains(this.scrollParent[0],this.offsetParent[0])&&(e.left+=this.scrollParent.scrollLeft(),e.top+=this.scrollParent.scrollTop()),(this.offsetParent[0]===document.body||this.offsetParent[0].tagName&&\"html\"===this.offsetParent[0].tagName.toLowerCase()&&t.ui.ie)&&(e={top:0,left:0}),{top:e.top+(parseInt(this.offsetParent.css(\"borderTopWidth\"),10)||0),left:e.left+(parseInt(this.offsetParent.css(\"borderLeftWidth\"),10)||0)}},_getRelativeOffset:function(){if(\"relative\"===this.cssPosition){var t=this.currentItem.position();return{top:t.top-(parseInt(this.helper.css(\"top\"),10)||0)+this.scrollParent.scrollTop(),left:t.left-(parseInt(this.helper.css(\"left\"),10)||0)+this.scrollParent.scrollLeft()}}return{top:0,left:0}},_cacheMargins:function(){this.margins={left:parseInt(this.currentItem.css(\"marginLeft\"),10)||0,top:parseInt(this.currentItem.css(\"marginTop\"),10)||0}},_cacheHelperProportions:function(){this.helperProportions={width:this.helper.outerWidth(),height:this.helper.outerHeight()}},_setContainment:function(){var e,i,s,n=this.options;\"parent\"===n.containment&&(n.containment=this.helper[0].parentNode),(\"document\"===n.containment||\"window\"===n.containment)&&(this.containment=[0-this.offset.relative.left-this.offset.parent.left,0-this.offset.relative.top-this.offset.parent.top,t(\"document\"===n.containment?document:window).width()-this.helperProportions.width-this.margins.left,(t(\"document\"===n.containment?document:window).height()||document.body.parentNode.scrollHeight)-this.helperProportions.height-this.margins.top]),/^(document|window|parent)$/.test(n.containment)||(e=t(n.containment)[0],i=t(n.containment).offset(),s=\"hidden\"!==t(e).css(\"overflow\"),this.containment=[i.left+(parseInt(t(e).css(\"borderLeftWidth\"),10)||0)+(parseInt(t(e).css(\"paddingLeft\"),10)||0)-this.margins.left,i.top+(parseInt(t(e).css(\"borderTopWidth\"),10)||0)+(parseInt(t(e).css(\"paddingTop\"),10)||0)-this.margins.top,i.left+(s?Math.max(e.scrollWidth,e.offsetWidth):e.offsetWidth)-(parseInt(t(e).css(\"borderLeftWidth\"),10)||0)-(parseInt(t(e).css(\"paddingRight\"),10)||0)-this.helperProportions.width-this.margins.left,i.top+(s?Math.max(e.scrollHeight,e.offsetHeight):e.offsetHeight)-(parseInt(t(e).css(\"borderTopWidth\"),10)||0)-(parseInt(t(e).css(\"paddingBottom\"),10)||0)-this.helperProportions.height-this.margins.top])},_convertPositionTo:function(e,i){i||(i=this.position);var s=\"absolute\"===e?1:-1,n=\"absolute\"!==this.cssPosition||this.scrollParent[0]!==document&&t.contains(this.scrollParent[0],this.offsetParent[0])?this.scrollParent:this.offsetParent,o=/(html|body)/i.test(n[0].tagName);return{top:i.top+this.offset.relative.top*s+this.offset.parent.top*s-(\"fixed\"===this.cssPosition?-this.scrollParent.scrollTop():o?0:n.scrollTop())*s,left:i.left+this.offset.relative.left*s+this.offset.parent.left*s-(\"fixed\"===this.cssPosition?-this.scrollParent.scrollLeft():o?0:n.scrollLeft())*s}},_generatePosition:function(e){var i,s,n=this.options,o=e.pageX,a=e.pageY,r=\"absolute\"!==this.cssPosition||this.scrollParent[0]!==document&&t.contains(this.scrollParent[0],this.offsetParent[0])?this.scrollParent:this.offsetParent,h=/(html|body)/i.test(r[0].tagName);return\"relative\"!==this.cssPosition||this.scrollParent[0]!==document&&this.scrollParent[0]!==this.offsetParent[0]||(this.offset.relative=this._getRelativeOffset()),this.originalPosition&&(this.containment&&(e.pageX-this.offset.click.left<this.containment[0]&&(o=this.containment[0]+this.offset.click.left),e.pageY-this.offset.click.top<this.containment[1]&&(a=this.containment[1]+this.offset.click.top),e.pageX-this.offset.click.left>this.containment[2]&&(o=this.containment[2]+this.offset.click.left),e.pageY-this.offset.click.top>this.containment[3]&&(a=this.containment[3]+this.offset.click.top)),n.grid&&(i=this.originalPageY+Math.round((a-this.originalPageY)/n.grid[1])*n.grid[1],a=this.containment?i-this.offset.click.top>=this.containment[1]&&i-this.offset.click.top<=this.containment[3]?i:i-this.offset.click.top>=this.containment[1]?i-n.grid[1]:i+n.grid[1]:i,s=this.originalPageX+Math.round((o-this.originalPageX)/n.grid[0])*n.grid[0],o=this.containment?s-this.offset.click.left>=this.containment[0]&&s-this.offset.click.left<=this.containment[2]?s:s-this.offset.click.left>=this.containment[0]?s-n.grid[0]:s+n.grid[0]:s)),{top:a-this.offset.click.top-this.offset.relative.top-this.offset.parent.top+(\"fixed\"===this.cssPosition?-this.scrollParent.scrollTop():h?0:r.scrollTop()),left:o-this.offset.click.left-this.offset.relative.left-this.offset.parent.left+(\"fixed\"===this.cssPosition?-this.scrollParent.scrollLeft():h?0:r.scrollLeft())}},_rearrange:function(t,e,i,s){i?i[0].appendChild(this.placeholder[0]):e.item[0].parentNode.insertBefore(this.placeholder[0],\"down\"===this.direction?e.item[0]:e.item[0].nextSibling),this.counter=this.counter?++this.counter:1;var n=this.counter;this._delay(function(){n===this.counter&&this.refreshPositions(!s)})},_clear:function(t,e){function i(t,e,i){return function(s){i._trigger(t,s,e._uiHash(e))}}this.reverting=!1;var s,n=[];if(!this._noFinalSort&&this.currentItem.parent().length&&this.placeholder.before(this.currentItem),this._noFinalSort=null,this.helper[0]===this.currentItem[0]){for(s in this._storedCSS)(\"auto\"===this._storedCSS[s]||\"static\"===this._storedCSS[s])&&(this._storedCSS[s]=\"\");this.currentItem.css(this._storedCSS).removeClass(\"ui-sortable-helper\")}else this.currentItem.show();for(this.fromOutside&&!e&&n.push(function(t){this._trigger(\"receive\",t,this._uiHash(this.fromOutside))}),!this.fromOutside&&this.domPosition.prev===this.currentItem.prev().not(\".ui-sortable-helper\")[0]&&this.domPosition.parent===this.currentItem.parent()[0]||e||n.push(function(t){this._trigger(\"update\",t,this._uiHash())}),this!==this.currentContainer&&(e||(n.push(function(t){this._trigger(\"remove\",t,this._uiHash())}),n.push(function(t){return function(e){t._trigger(\"receive\",e,this._uiHash(this))}}.call(this,this.currentContainer)),n.push(function(t){return function(e){t._trigger(\"update\",e,this._uiHash(this))}}.call(this,this.currentContainer)))),s=this.containers.length-1;s>=0;s--)e||n.push(i(\"deactivate\",this,this.containers[s])),this.containers[s].containerCache.over&&(n.push(i(\"out\",this,this.containers[s])),this.containers[s].containerCache.over=0);if(this.storedCursor&&(this.document.find(\"body\").css(\"cursor\",this.storedCursor),this.storedStylesheet.remove()),this._storedOpacity&&this.helper.css(\"opacity\",this._storedOpacity),this._storedZIndex&&this.helper.css(\"zIndex\",\"auto\"===this._storedZIndex?\"\":this._storedZIndex),this.dragging=!1,this.cancelHelperRemoval){if(!e){for(this._trigger(\"beforeStop\",t,this._uiHash()),s=0;n.length>s;s++)n[s].call(this,t);this._trigger(\"stop\",t,this._uiHash())}return this.fromOutside=!1,!1}if(e||this._trigger(\"beforeStop\",t,this._uiHash()),this.placeholder[0].parentNode.removeChild(this.placeholder[0]),this.helper[0]!==this.currentItem[0]&&this.helper.remove(),this.helper=null,!e){for(s=0;n.length>s;s++)n[s].call(this,t);this._trigger(\"stop\",t,this._uiHash())}return this.fromOutside=!1,!0},_trigger:function(){t.Widget.prototype._trigger.apply(this,arguments)===!1&&this.cancel()},_uiHash:function(e){var i=e||this;return{helper:i.helper,placeholder:i.placeholder||t([]),position:i.position,originalPosition:i.originalPosition,offset:i.positionAbs,item:i.currentItem,sender:e?e.element:null}}})}(jQuery),function(t,e){var i=\"ui-effects-\";t.effects={effect:{}},function(t,e){function i(t,e,i){var s=u[e.type]||{};return null==t?i||!e.def?null:e.def:(t=s.floor?~~t:parseFloat(t),isNaN(t)?e.def:s.mod?(t+s.mod)%s.mod:0>t?0:t>s.max?s.max:t)}function s(i){var s=l(),n=s._rgba=[];return i=i.toLowerCase(),f(h,function(t,o){var a,r=o.re.exec(i),h=r&&o.parse(r),l=o.space||\"rgba\";return h?(a=s[l](h),s[c[l].cache]=a[c[l].cache],n=s._rgba=a._rgba,!1):e}),n.length?(\"0,0,0,0\"===n.join()&&t.extend(n,o.transparent),s):o[i]}function n(t,e,i){return i=(i+1)%1,1>6*i?t+6*(e-t)*i:1>2*i?e:2>3*i?t+6*(e-t)*(2/3-i):t}var o,a=\"backgroundColor borderBottomColor borderLeftColor borderRightColor borderTopColor color columnRuleColor outlineColor textDecorationColor textEmphasisColor\",r=/^([\\-+])=\\s*(\\d+\\.?\\d*)/,h=[{re:/rgba?\\(\\s*(\\d{1,3})\\s*,\\s*(\\d{1,3})\\s*,\\s*(\\d{1,3})\\s*(?:,\\s*(\\d?(?:\\.\\d+)?)\\s*)?\\)/,parse:function(t){return[t[1],t[2],t[3],t[4]]}},{re:/rgba?\\(\\s*(\\d+(?:\\.\\d+)?)\\%\\s*,\\s*(\\d+(?:\\.\\d+)?)\\%\\s*,\\s*(\\d+(?:\\.\\d+)?)\\%\\s*(?:,\\s*(\\d?(?:\\.\\d+)?)\\s*)?\\)/,parse:function(t){return[2.55*t[1],2.55*t[2],2.55*t[3],t[4]]}},{re:/#([a-f0-9]{2})([a-f0-9]{2})([a-f0-9]{2})/,parse:function(t){return[parseInt(t[1],16),parseInt(t[2],16),parseInt(t[3],16)]}},{re:/#([a-f0-9])([a-f0-9])([a-f0-9])/,parse:function(t){return[parseInt(t[1]+t[1],16),parseInt(t[2]+t[2],16),parseInt(t[3]+t[3],16)]}},{re:/hsla?\\(\\s*(\\d+(?:\\.\\d+)?)\\s*,\\s*(\\d+(?:\\.\\d+)?)\\%\\s*,\\s*(\\d+(?:\\.\\d+)?)\\%\\s*(?:,\\s*(\\d?(?:\\.\\d+)?)\\s*)?\\)/,space:\"hsla\",parse:function(t){return[t[1],t[2]/100,t[3]/100,t[4]]}}],l=t.Color=function(e,i,s,n){return new t.Color.fn.parse(e,i,s,n)},c={rgba:{props:{red:{idx:0,type:\"byte\"},green:{idx:1,type:\"byte\"},blue:{idx:2,type:\"byte\"}}},hsla:{props:{hue:{idx:0,type:\"degrees\"},saturation:{idx:1,type:\"percent\"},lightness:{idx:2,type:\"percent\"}}}},u={\"byte\":{floor:!0,max:255},percent:{max:1},degrees:{mod:360,floor:!0}},d=l.support={},p=t(\"<p>\")[0],f=t.each;p.style.cssText=\"background-color:rgba(1,1,1,.5)\",d.rgba=p.style.backgroundColor.indexOf(\"rgba\")>-1,f(c,function(t,e){e.cache=\"_\"+t,e.props.alpha={idx:3,type:\"percent\",def:1}}),l.fn=t.extend(l.prototype,{parse:function(n,a,r,h){if(n===e)return this._rgba=[null,null,null,null],this;(n.jquery||n.nodeType)&&(n=t(n).css(a),a=e);var u=this,d=t.type(n),p=this._rgba=[];return a!==e&&(n=[n,a,r,h],d=\"array\"),\"string\"===d?this.parse(s(n)||o._default):\"array\"===d?(f(c.rgba.props,function(t,e){p[e.idx]=i(n[e.idx],e)}),this):\"object\"===d?(n instanceof l?f(c,function(t,e){n[e.cache]&&(u[e.cache]=n[e.cache].slice())}):f(c,function(e,s){var o=s.cache;f(s.props,function(t,e){if(!u[o]&&s.to){if(\"alpha\"===t||null==n[t])return;u[o]=s.to(u._rgba)}u[o][e.idx]=i(n[t],e,!0)}),u[o]&&0>t.inArray(null,u[o].slice(0,3))&&(u[o][3]=1,s.from&&(u._rgba=s.from(u[o])))}),this):e},is:function(t){var i=l(t),s=!0,n=this;return f(c,function(t,o){var a,r=i[o.cache];return r&&(a=n[o.cache]||o.to&&o.to(n._rgba)||[],f(o.props,function(t,i){return null!=r[i.idx]?s=r[i.idx]===a[i.idx]:e})),s}),s},_space:function(){var t=[],e=this;return f(c,function(i,s){e[s.cache]&&t.push(i)}),t.pop()},transition:function(t,e){var s=l(t),n=s._space(),o=c[n],a=0===this.alpha()?l(\"transparent\"):this,r=a[o.cache]||o.to(a._rgba),h=r.slice();return s=s[o.cache],f(o.props,function(t,n){var o=n.idx,a=r[o],l=s[o],c=u[n.type]||{};null!==l&&(null===a?h[o]=l:(c.mod&&(l-a>c.mod/2?a+=c.mod:a-l>c.mod/2&&(a-=c.mod)),h[o]=i((l-a)*e+a,n)))}),this[n](h)},blend:function(e){if(1===this._rgba[3])return this;var i=this._rgba.slice(),s=i.pop(),n=l(e)._rgba;return l(t.map(i,function(t,e){return(1-s)*n[e]+s*t}))},toRgbaString:function(){var e=\"rgba(\",i=t.map(this._rgba,function(t,e){return null==t?e>2?1:0:t});return 1===i[3]&&(i.pop(),e=\"rgb(\"),e+i.join()+\")\"},toHslaString:function(){var e=\"hsla(\",i=t.map(this.hsla(),function(t,e){return null==t&&(t=e>2?1:0),e&&3>e&&(t=Math.round(100*t)+\"%\"),t});return 1===i[3]&&(i.pop(),e=\"hsl(\"),e+i.join()+\")\"},toHexString:function(e){var i=this._rgba.slice(),s=i.pop();return e&&i.push(~~(255*s)),\"#\"+t.map(i,function(t){return t=(t||0).toString(16),1===t.length?\"0\"+t:t}).join(\"\")},toString:function(){return 0===this._rgba[3]?\"transparent\":this.toRgbaString()}}),l.fn.parse.prototype=l.fn,c.hsla.to=function(t){if(null==t[0]||null==t[1]||null==t[2])return[null,null,null,t[3]];var e,i,s=t[0]/255,n=t[1]/255,o=t[2]/255,a=t[3],r=Math.max(s,n,o),h=Math.min(s,n,o),l=r-h,c=r+h,u=.5*c;return e=h===r?0:s===r?60*(n-o)/l+360:n===r?60*(o-s)/l+120:60*(s-n)/l+240,i=0===l?0:.5>=u?l/c:l/(2-c),[Math.round(e)%360,i,u,null==a?1:a]},c.hsla.from=function(t){if(null==t[0]||null==t[1]||null==t[2])return[null,null,null,t[3]];var e=t[0]/360,i=t[1],s=t[2],o=t[3],a=.5>=s?s*(1+i):s+i-s*i,r=2*s-a;return[Math.round(255*n(r,a,e+1/3)),Math.round(255*n(r,a,e)),Math.round(255*n(r,a,e-1/3)),o]},f(c,function(s,n){var o=n.props,a=n.cache,h=n.to,c=n.from;l.fn[s]=function(s){if(h&&!this[a]&&(this[a]=h(this._rgba)),s===e)return this[a].slice();var n,r=t.type(s),u=\"array\"===r||\"object\"===r?s:arguments,d=this[a].slice();return f(o,function(t,e){var s=u[\"object\"===r?t:e.idx];null==s&&(s=d[e.idx]),d[e.idx]=i(s,e)}),c?(n=l(c(d)),n[a]=d,n):l(d)},f(o,function(e,i){l.fn[e]||(l.fn[e]=function(n){var o,a=t.type(n),h=\"alpha\"===e?this._hsla?\"hsla\":\"rgba\":s,l=this[h](),c=l[i.idx];return\"undefined\"===a?c:(\"function\"===a&&(n=n.call(this,c),a=t.type(n)),null==n&&i.empty?this:(\"string\"===a&&(o=r.exec(n),o&&(n=c+parseFloat(o[2])*(\"+\"===o[1]?1:-1))),l[i.idx]=n,this[h](l)))})})}),l.hook=function(e){var i=e.split(\" \");f(i,function(e,i){t.cssHooks[i]={set:function(e,n){var o,a,r=\"\";if(\"transparent\"!==n&&(\"string\"!==t.type(n)||(o=s(n)))){if(n=l(o||n),!d.rgba&&1!==n._rgba[3]){for(a=\"backgroundColor\"===i?e.parentNode:e;(\"\"===r||\"transparent\"===r)&&a&&a.style;)try{r=t.css(a,\"backgroundColor\"),a=a.parentNode}catch(h){}n=n.blend(r&&\"transparent\"!==r?r:\"_default\")}n=n.toRgbaString()}try{e.style[i]=n}catch(h){}}},t.fx.step[i]=function(e){e.colorInit||(e.start=l(e.elem,i),e.end=l(e.end),e.colorInit=!0),t.cssHooks[i].set(e.elem,e.start.transition(e.end,e.pos))}})},l.hook(a),t.cssHooks.borderColor={expand:function(t){var e={};return f([\"Top\",\"Right\",\"Bottom\",\"Left\"],function(i,s){e[\"border\"+s+\"Color\"]=t}),e}},o=t.Color.names={aqua:\"#00ffff\",black:\"#000000\",blue:\"#0000ff\",fuchsia:\"#ff00ff\",gray:\"#808080\",green:\"#008000\",lime:\"#00ff00\",maroon:\"#800000\",navy:\"#000080\",olive:\"#808000\",purple:\"#800080\",red:\"#e03f32\",silver:\"#c0c0c0\",teal:\"#008080\",white:\"#ffffff\",yellow:\"#ffff00\",transparent:[null,null,null,0],_default:\"#ffffff\"}}(jQuery),function(){function i(e){var i,s,n=e.ownerDocument.defaultView?e.ownerDocument.defaultView.getComputedStyle(e,null):e.currentStyle,o={};if(n&&n.length&&n[0]&&n[n[0]])for(s=n.length;s--;)i=n[s],\"string\"==typeof n[i]&&(o[t.camelCase(i)]=n[i]);else for(i in n)\"string\"==typeof n[i]&&(o[i]=n[i]);return o}function s(e,i){var s,n,a={};for(s in i)n=i[s],e[s]!==n&&(o[s]||(t.fx.step[s]||!isNaN(parseFloat(n)))&&(a[s]=n));return a}var n=[\"add\",\"remove\",\"toggle\"],o={border:1,borderBottom:1,borderColor:1,borderLeft:1,borderRight:1,borderTop:1,borderWidth:1,margin:1,padding:1};t.each([\"borderLeftStyle\",\"borderRightStyle\",\"borderBottomStyle\",\"borderTopStyle\"],function(e,i){t.fx.step[i]=function(t){(\"none\"!==t.end&&!t.setAttr||1===t.pos&&!t.setAttr)&&(jQuery.style(t.elem,i,t.end),t.setAttr=!0)}}),t.fn.addBack||(t.fn.addBack=function(t){return this.add(null==t?this.prevObject:this.prevObject.filter(t))}),t.effects.animateClass=function(e,o,a,r){var h=t.speed(o,a,r);return this.queue(function(){var o,a=t(this),r=a.attr(\"class\")||\"\",l=h.children?a.find(\"*\").addBack():a;l=l.map(function(){var e=t(this);return{el:e,start:i(this)}}),o=function(){t.each(n,function(t,i){e[i]&&a[i+\"Class\"](e[i])})},o(),l=l.map(function(){return this.end=i(this.el[0]),this.diff=s(this.start,this.end),this}),a.attr(\"class\",r),l=l.map(function(){var e=this,i=t.Deferred(),s=t.extend({},h,{queue:!1,complete:function(){i.resolve(e)}});return this.el.animate(this.diff,s),i.promise()}),t.when.apply(t,l.get()).done(function(){o(),t.each(arguments,function(){var e=this.el;t.each(this.diff,function(t){e.css(t,\"\")})}),h.complete.call(a[0])})})},t.fn.extend({addClass:function(e){return function(i,s,n,o){return s?t.effects.animateClass.call(this,{add:i},s,n,o):e.apply(this,arguments)}}(t.fn.addClass),removeClass:function(e){return function(i,s,n,o){return arguments.length>1?t.effects.animateClass.call(this,{remove:i},s,n,o):e.apply(this,arguments)}}(t.fn.removeClass),toggleClass:function(i){return function(s,n,o,a,r){return\"boolean\"==typeof n||n===e?o?t.effects.animateClass.call(this,n?{add:s}:{remove:s},o,a,r):i.apply(this,arguments):t.effects.animateClass.call(this,{toggle:s},n,o,a)}}(t.fn.toggleClass),switchClass:function(e,i,s,n,o){return t.effects.animateClass.call(this,{add:i,remove:e},s,n,o)}})}(),function(){function s(e,i,s,n){return t.isPlainObject(e)&&(i=e,e=e.effect),e={effect:e},null==i&&(i={}),t.isFunction(i)&&(n=i,s=null,i={}),(\"number\"==typeof i||t.fx.speeds[i])&&(n=s,s=i,i={}),t.isFunction(s)&&(n=s,s=null),i&&t.extend(e,i),s=s||i.duration,e.duration=t.fx.off?0:\"number\"==typeof s?s:s in t.fx.speeds?t.fx.speeds[s]:t.fx.speeds._default,e.complete=n||i.complete,e}function n(e){return!e||\"number\"==typeof e||t.fx.speeds[e]?!0:\"string\"!=typeof e||t.effects.effect[e]?t.isFunction(e)?!0:\"object\"!=typeof e||e.effect?!1:!0:!0}t.extend(t.effects,{version:\"1.10.4\",save:function(t,e){for(var s=0;e.length>s;s++)null!==e[s]&&t.data(i+e[s],t[0].style[e[s]])},restore:function(t,s){var n,o;for(o=0;s.length>o;o++)null!==s[o]&&(n=t.data(i+s[o]),n===e&&(n=\"\"),t.css(s[o],n))},setMode:function(t,e){return\"toggle\"===e&&(e=t.is(\":hidden\")?\"show\":\"hide\"),e},getBaseline:function(t,e){var i,s;switch(t[0]){case\"top\":i=0;break;case\"middle\":i=.5;break;case\"bottom\":i=1;break;default:i=t[0]/e.height}switch(t[1]){case\"left\":s=0;break;case\"center\":s=.5;break;case\"right\":s=1;break;default:s=t[1]/e.width}return{x:s,y:i}},createWrapper:function(e){if(e.parent().is(\".ui-effects-wrapper\"))return e.parent();var i={width:e.outerWidth(!0),height:e.outerHeight(!0),\"float\":e.css(\"float\")},s=t(\"<div></div>\").addClass(\"ui-effects-wrapper\").css({fontSize:\"100%\",background:\"transparent\",border:\"none\",margin:0,padding:0}),n={width:e.width(),height:e.height()},o=document.activeElement;try{o.id}catch(a){o=document.body}return e.wrap(s),(e[0]===o||t.contains(e[0],o))&&t(o).focus(),s=e.parent(),\"static\"===e.css(\"position\")?(s.css({position:\"relative\"}),e.css({position:\"relative\"})):(t.extend(i,{position:e.css(\"position\"),zIndex:e.css(\"z-index\")}),t.each([\"top\",\"left\",\"bottom\",\"right\"],function(t,s){i[s]=e.css(s),isNaN(parseInt(i[s],10))&&(i[s]=\"auto\")}),e.css({position:\"relative\",top:0,left:0,right:\"auto\",bottom:\"auto\"})),e.css(n),s.css(i).show()},removeWrapper:function(e){var i=document.activeElement;return e.parent().is(\".ui-effects-wrapper\")&&(e.parent().replaceWith(e),(e[0]===i||t.contains(e[0],i))&&t(i).focus()),e},setTransition:function(e,i,s,n){return n=n||{},t.each(i,function(t,i){var o=e.cssUnit(i);o[0]>0&&(n[i]=o[0]*s+o[1])}),n}}),t.fn.extend({effect:function(){function e(e){function s(){t.isFunction(o)&&o.call(n[0]),t.isFunction(e)&&e()}var n=t(this),o=i.complete,r=i.mode;(n.is(\":hidden\")?\"hide\"===r:\"show\"===r)?(n[r](),s()):a.call(n[0],i,s)}var i=s.apply(this,arguments),n=i.mode,o=i.queue,a=t.effects.effect[i.effect];return t.fx.off||!a?n?this[n](i.duration,i.complete):this.each(function(){i.complete&&i.complete.call(this)}):o===!1?this.each(e):this.queue(o||\"fx\",e)},show:function(t){return function(e){if(n(e))return t.apply(this,arguments);var i=s.apply(this,arguments);return i.mode=\"show\",this.effect.call(this,i)}}(t.fn.show),hide:function(t){return function(e){if(n(e))return t.apply(this,arguments);var i=s.apply(this,arguments);return i.mode=\"hide\",this.effect.call(this,i)}}(t.fn.hide),toggle:function(t){return function(e){if(n(e)||\"boolean\"==typeof e)return t.apply(this,arguments);var i=s.apply(this,arguments);return i.mode=\"toggle\",this.effect.call(this,i)}}(t.fn.toggle),cssUnit:function(e){var i=this.css(e),s=[];return t.each([\"em\",\"px\",\"%\",\"pt\"],function(t,e){i.indexOf(e)>0&&(s=[parseFloat(i),e])}),s}})}(),function(){var e={};t.each([\"Quad\",\"Cubic\",\"Quart\",\"Quint\",\"Expo\"],function(t,i){e[i]=function(e){return Math.pow(e,t+2)}}),t.extend(e,{Sine:function(t){return 1-Math.cos(t*Math.PI/2)},Circ:function(t){return 1-Math.sqrt(1-t*t)},Elastic:function(t){return 0===t||1===t?t:-Math.pow(2,8*(t-1))*Math.sin((80*(t-1)-7.5)*Math.PI/15)},Back:function(t){return t*t*(3*t-2)},Bounce:function(t){for(var e,i=4;((e=Math.pow(2,--i))-1)/11>t;);return 1/Math.pow(4,3-i)-7.5625*Math.pow((3*e-2)/22-t,2)}}),t.each(e,function(e,i){t.easing[\"easeIn\"+e]=i,t.easing[\"easeOut\"+e]=function(t){return 1-i(1-t)},t.easing[\"easeInOut\"+e]=function(t){return.5>t?i(2*t)/2:1-i(-2*t+2)/2}})}()}(jQuery),function(t){var e=0,i={},s={};i.height=i.paddingTop=i.paddingBottom=i.borderTopWidth=i.borderBottomWidth=\"hide\",s.height=s.paddingTop=s.paddingBottom=s.borderTopWidth=s.borderBottomWidth=\"show\",t.widget(\"ui.accordion\",{version:\"1.10.4\",options:{active:0,animate:{},collapsible:!1,event:\"click\",header:\"> li > :first-child,> :not(li):even\",heightStyle:\"auto\",icons:{activeHeader:\"ui-icon-triangle-1-s\",header:\"ui-icon-triangle-1-e\"},activate:null,beforeActivate:null},_create:function(){var e=this.options;this.prevShow=this.prevHide=t(),this.element.addClass(\"ui-accordion ui-widget ui-helper-reset\").attr(\"role\",\"tablist\"),e.collapsible||e.active!==!1&&null!=e.active||(e.active=0),this._processPanels(),0>e.active&&(e.active+=this.headers.length),this._refresh()},_getCreateEventData:function(){return{header:this.active,panel:this.active.length?this.active.next():t(),content:this.active.length?this.active.next():t()}},_createIcons:function(){var e=this.options.icons;e&&(t(\"<span>\").addClass(\"ui-accordion-header-icon ui-icon \"+e.header).prependTo(this.headers),this.active.children(\".ui-accordion-header-icon\").removeClass(e.header).addClass(e.activeHeader),this.headers.addClass(\"ui-accordion-icons\"))\n" +
                    "},_destroyIcons:function(){this.headers.removeClass(\"ui-accordion-icons\").children(\".ui-accordion-header-icon\").remove()},_destroy:function(){var t;this.element.removeClass(\"ui-accordion ui-widget ui-helper-reset\").removeAttr(\"role\"),this.headers.removeClass(\"ui-accordion-header ui-accordion-header-active ui-helper-reset ui-state-default ui-corner-all ui-state-active ui-state-disabled ui-corner-top\").removeAttr(\"role\").removeAttr(\"aria-expanded\").removeAttr(\"aria-selected\").removeAttr(\"aria-controls\").removeAttr(\"tabIndex\").each(function(){/^ui-accordion/.test(this.id)&&this.removeAttribute(\"id\")}),this._destroyIcons(),t=this.headers.next().css(\"display\",\"\").removeAttr(\"role\").removeAttr(\"aria-hidden\").removeAttr(\"aria-labelledby\").removeClass(\"ui-helper-reset ui-widget-content ui-corner-bottom ui-accordion-content ui-accordion-content-active ui-state-disabled\").each(function(){/^ui-accordion/.test(this.id)&&this.removeAttribute(\"id\")}),\"content\"!==this.options.heightStyle&&t.css(\"height\",\"\")},_setOption:function(t,e){return\"active\"===t?(this._activate(e),undefined):(\"event\"===t&&(this.options.event&&this._off(this.headers,this.options.event),this._setupEvents(e)),this._super(t,e),\"collapsible\"!==t||e||this.options.active!==!1||this._activate(0),\"icons\"===t&&(this._destroyIcons(),e&&this._createIcons()),\"disabled\"===t&&this.headers.add(this.headers.next()).toggleClass(\"ui-state-disabled\",!!e),undefined)},_keydown:function(e){if(!e.altKey&&!e.ctrlKey){var i=t.ui.keyCode,s=this.headers.length,n=this.headers.index(e.target),o=!1;switch(e.keyCode){case i.RIGHT:case i.DOWN:o=this.headers[(n+1)%s];break;case i.LEFT:case i.UP:o=this.headers[(n-1+s)%s];break;case i.SPACE:case i.ENTER:this._eventHandler(e);break;case i.HOME:o=this.headers[0];break;case i.END:o=this.headers[s-1]}o&&(t(e.target).attr(\"tabIndex\",-1),t(o).attr(\"tabIndex\",0),o.focus(),e.preventDefault())}},_panelKeyDown:function(e){e.keyCode===t.ui.keyCode.UP&&e.ctrlKey&&t(e.currentTarget).prev().focus()},refresh:function(){var e=this.options;this._processPanels(),e.active===!1&&e.collapsible===!0||!this.headers.length?(e.active=!1,this.active=t()):e.active===!1?this._activate(0):this.active.length&&!t.contains(this.element[0],this.active[0])?this.headers.length===this.headers.find(\".ui-state-disabled\").length?(e.active=!1,this.active=t()):this._activate(Math.max(0,e.active-1)):e.active=this.headers.index(this.active),this._destroyIcons(),this._refresh()},_processPanels:function(){this.headers=this.element.find(this.options.header).addClass(\"ui-accordion-header ui-helper-reset ui-state-default ui-corner-all\"),this.headers.next().addClass(\"ui-accordion-content ui-helper-reset ui-widget-content ui-corner-bottom\").filter(\":not(.ui-accordion-content-active)\").hide()},_refresh:function(){var i,s=this.options,n=s.heightStyle,o=this.element.parent(),a=this.accordionId=\"ui-accordion-\"+(this.element.attr(\"id\")||++e);this.active=this._findActive(s.active).addClass(\"ui-accordion-header-active ui-state-active ui-corner-top\").removeClass(\"ui-corner-all\"),this.active.next().addClass(\"ui-accordion-content-active\").show(),this.headers.attr(\"role\",\"tab\").each(function(e){var i=t(this),s=i.attr(\"id\"),n=i.next(),o=n.attr(\"id\");s||(s=a+\"-header-\"+e,i.attr(\"id\",s)),o||(o=a+\"-panel-\"+e,n.attr(\"id\",o)),i.attr(\"aria-controls\",o),n.attr(\"aria-labelledby\",s)}).next().attr(\"role\",\"tabpanel\"),this.headers.not(this.active).attr({\"aria-selected\":\"false\",\"aria-expanded\":\"false\",tabIndex:-1}).next().attr({\"aria-hidden\":\"true\"}).hide(),this.active.length?this.active.attr({\"aria-selected\":\"true\",\"aria-expanded\":\"true\",tabIndex:0}).next().attr({\"aria-hidden\":\"false\"}):this.headers.eq(0).attr(\"tabIndex\",0),this._createIcons(),this._setupEvents(s.event),\"fill\"===n?(i=o.height(),this.element.siblings(\":visible\").each(function(){var e=t(this),s=e.css(\"position\");\"absolute\"!==s&&\"fixed\"!==s&&(i-=e.outerHeight(!0))}),this.headers.each(function(){i-=t(this).outerHeight(!0)}),this.headers.next().each(function(){t(this).height(Math.max(0,i-t(this).innerHeight()+t(this).height()))}).css(\"overflow\",\"auto\")):\"auto\"===n&&(i=0,this.headers.next().each(function(){i=Math.max(i,t(this).css(\"height\",\"\").height())}).height(i))},_activate:function(e){var i=this._findActive(e)[0];i!==this.active[0]&&(i=i||this.active[0],this._eventHandler({target:i,currentTarget:i,preventDefault:t.noop}))},_findActive:function(e){return\"number\"==typeof e?this.headers.eq(e):t()},_setupEvents:function(e){var i={keydown:\"_keydown\"};e&&t.each(e.split(\" \"),function(t,e){i[e]=\"_eventHandler\"}),this._off(this.headers.add(this.headers.next())),this._on(this.headers,i),this._on(this.headers.next(),{keydown:\"_panelKeyDown\"}),this._hoverable(this.headers),this._focusable(this.headers)},_eventHandler:function(e){var i=this.options,s=this.active,n=t(e.currentTarget),o=n[0]===s[0],a=o&&i.collapsible,r=a?t():n.next(),h=s.next(),l={oldHeader:s,oldPanel:h,newHeader:a?t():n,newPanel:r};e.preventDefault(),o&&!i.collapsible||this._trigger(\"beforeActivate\",e,l)===!1||(i.active=a?!1:this.headers.index(n),this.active=o?t():n,this._toggle(l),s.removeClass(\"ui-accordion-header-active ui-state-active\"),i.icons&&s.children(\".ui-accordion-header-icon\").removeClass(i.icons.activeHeader).addClass(i.icons.header),o||(n.removeClass(\"ui-corner-all\").addClass(\"ui-accordion-header-active ui-state-active ui-corner-top\"),i.icons&&n.children(\".ui-accordion-header-icon\").removeClass(i.icons.header).addClass(i.icons.activeHeader),n.next().addClass(\"ui-accordion-content-active\")))},_toggle:function(e){var i=e.newPanel,s=this.prevShow.length?this.prevShow:e.oldPanel;this.prevShow.add(this.prevHide).stop(!0,!0),this.prevShow=i,this.prevHide=s,this.options.animate?this._animate(i,s,e):(s.hide(),i.show(),this._toggleComplete(e)),s.attr({\"aria-hidden\":\"true\"}),s.prev().attr(\"aria-selected\",\"false\"),i.length&&s.length?s.prev().attr({tabIndex:-1,\"aria-expanded\":\"false\"}):i.length&&this.headers.filter(function(){return 0===t(this).attr(\"tabIndex\")}).attr(\"tabIndex\",-1),i.attr(\"aria-hidden\",\"false\").prev().attr({\"aria-selected\":\"true\",tabIndex:0,\"aria-expanded\":\"true\"})},_animate:function(t,e,n){var o,a,r,h=this,l=0,c=t.length&&(!e.length||t.index()<e.index()),u=this.options.animate||{},d=c&&u.down||u,p=function(){h._toggleComplete(n)};return\"number\"==typeof d&&(r=d),\"string\"==typeof d&&(a=d),a=a||d.easing||u.easing,r=r||d.duration||u.duration,e.length?t.length?(o=t.show().outerHeight(),e.animate(i,{duration:r,easing:a,step:function(t,e){e.now=Math.round(t)}}),t.hide().animate(s,{duration:r,easing:a,complete:p,step:function(t,i){i.now=Math.round(t),\"height\"!==i.prop?l+=i.now:\"content\"!==h.options.heightStyle&&(i.now=Math.round(o-e.outerHeight()-l),l=0)}}),undefined):e.animate(i,r,a,p):t.animate(s,r,a,p)},_toggleComplete:function(t){var e=t.oldPanel;e.removeClass(\"ui-accordion-content-active\").prev().removeClass(\"ui-corner-top\").addClass(\"ui-corner-all\"),e.length&&(e.parent()[0].className=e.parent()[0].className),this._trigger(\"activate\",null,t)}})}(jQuery),function(t){t.widget(\"ui.autocomplete\",{version:\"1.10.4\",defaultElement:\"<input>\",options:{appendTo:null,autoFocus:!1,delay:300,minLength:1,position:{my:\"left top\",at:\"left bottom\",collision:\"none\"},source:null,change:null,close:null,focus:null,open:null,response:null,search:null,select:null},requestIndex:0,pending:0,_create:function(){var e,i,s,n=this.element[0].nodeName.toLowerCase(),o=\"textarea\"===n,a=\"input\"===n;this.isMultiLine=o?!0:a?!1:this.element.prop(\"isContentEditable\"),this.valueMethod=this.element[o||a?\"val\":\"text\"],this.isNewMenu=!0,this.element.addClass(\"ui-autocomplete-input\").attr(\"autocomplete\",\"off\"),this._on(this.element,{keydown:function(n){if(this.element.prop(\"readOnly\"))return e=!0,s=!0,i=!0,undefined;e=!1,s=!1,i=!1;var o=t.ui.keyCode;switch(n.keyCode){case o.PAGE_UP:e=!0,this._move(\"previousPage\",n);break;case o.PAGE_DOWN:e=!0,this._move(\"nextPage\",n);break;case o.UP:e=!0,this._keyEvent(\"previous\",n);break;case o.DOWN:e=!0,this._keyEvent(\"next\",n);break;case o.ENTER:case o.NUMPAD_ENTER:this.menu.active&&(e=!0,n.preventDefault(),this.menu.select(n));break;case o.TAB:this.menu.active&&this.menu.select(n);break;case o.ESCAPE:this.menu.element.is(\":visible\")&&(this._value(this.term),this.close(n),n.preventDefault());break;default:i=!0,this._searchTimeout(n)}},keypress:function(s){if(e)return e=!1,(!this.isMultiLine||this.menu.element.is(\":visible\"))&&s.preventDefault(),undefined;if(!i){var n=t.ui.keyCode;switch(s.keyCode){case n.PAGE_UP:this._move(\"previousPage\",s);break;case n.PAGE_DOWN:this._move(\"nextPage\",s);break;case n.UP:this._keyEvent(\"previous\",s);break;case n.DOWN:this._keyEvent(\"next\",s)}}},input:function(t){return s?(s=!1,t.preventDefault(),undefined):(this._searchTimeout(t),undefined)},focus:function(){this.selectedItem=null,this.previous=this._value()},blur:function(t){return this.cancelBlur?(delete this.cancelBlur,undefined):(clearTimeout(this.searching),this.close(t),this._change(t),undefined)}}),this._initSource(),this.menu=t(\"<ul>\").addClass(\"ui-autocomplete ui-front\").appendTo(this._appendTo()).menu({role:null}).hide().data(\"ui-menu\"),this._on(this.menu.element,{mousedown:function(e){e.preventDefault(),this.cancelBlur=!0,this._delay(function(){delete this.cancelBlur});var i=this.menu.element[0];t(e.target).closest(\".ui-menu-item\").length||this._delay(function(){var e=this;this.document.one(\"mousedown\",function(s){s.target===e.element[0]||s.target===i||t.contains(i,s.target)||e.close()})})},menufocus:function(e,i){if(this.isNewMenu&&(this.isNewMenu=!1,e.originalEvent&&/^mouse/.test(e.originalEvent.type)))return this.menu.blur(),this.document.one(\"mousemove\",function(){t(e.target).trigger(e.originalEvent)}),undefined;var s=i.item.data(\"ui-autocomplete-item\");!1!==this._trigger(\"focus\",e,{item:s})?e.originalEvent&&/^key/.test(e.originalEvent.type)&&this._value(s.value):this.liveRegion.text(s.value)},menuselect:function(t,e){var i=e.item.data(\"ui-autocomplete-item\"),s=this.previous;this.element[0]!==this.document[0].activeElement&&(this.element.focus(),this.previous=s,this._delay(function(){this.previous=s,this.selectedItem=i})),!1!==this._trigger(\"select\",t,{item:i})&&this._value(i.value),this.term=this._value(),this.close(t),this.selectedItem=i}}),this.liveRegion=t(\"<span>\",{role:\"status\",\"aria-live\":\"polite\"}).addClass(\"ui-helper-hidden-accessible\").insertBefore(this.element),this._on(this.window,{beforeunload:function(){this.element.removeAttr(\"autocomplete\")}})},_destroy:function(){clearTimeout(this.searching),this.element.removeClass(\"ui-autocomplete-input\").removeAttr(\"autocomplete\"),this.menu.element.remove(),this.liveRegion.remove()},_setOption:function(t,e){this._super(t,e),\"source\"===t&&this._initSource(),\"appendTo\"===t&&this.menu.element.appendTo(this._appendTo()),\"disabled\"===t&&e&&this.xhr&&this.xhr.abort()},_appendTo:function(){var e=this.options.appendTo;return e&&(e=e.jquery||e.nodeType?t(e):this.document.find(e).eq(0)),e||(e=this.element.closest(\".ui-front\")),e.length||(e=this.document[0].body),e},_initSource:function(){var e,i,s=this;t.isArray(this.options.source)?(e=this.options.source,this.source=function(i,s){s(t.ui.autocomplete.filter(e,i.term))}):\"string\"==typeof this.options.source?(i=this.options.source,this.source=function(e,n){s.xhr&&s.xhr.abort(),s.xhr=t.ajax({url:i,data:e,dataType:\"json\",success:function(t){n(t)},error:function(){n([])}})}):this.source=this.options.source},_searchTimeout:function(t){clearTimeout(this.searching),this.searching=this._delay(function(){this.term!==this._value()&&(this.selectedItem=null,this.search(null,t))},this.options.delay)},search:function(t,e){return t=null!=t?t:this._value(),this.term=this._value(),t.length<this.options.minLength?this.close(e):this._trigger(\"search\",e)!==!1?this._search(t):undefined},_search:function(t){this.pending++,this.element.addClass(\"ui-autocomplete-loading\"),this.cancelSearch=!1,this.source({term:t},this._response())},_response:function(){var e=++this.requestIndex;return t.proxy(function(t){e===this.requestIndex&&this.__response(t),this.pending--,this.pending||this.element.removeClass(\"ui-autocomplete-loading\")},this)},__response:function(t){t&&(t=this._normalize(t)),this._trigger(\"response\",null,{content:t}),!this.options.disabled&&t&&t.length&&!this.cancelSearch?(this._suggest(t),this._trigger(\"open\")):this._close()},close:function(t){this.cancelSearch=!0,this._close(t)},_close:function(t){this.menu.element.is(\":visible\")&&(this.menu.element.hide(),this.menu.blur(),this.isNewMenu=!0,this._trigger(\"close\",t))},_change:function(t){this.previous!==this._value()&&this._trigger(\"change\",t,{item:this.selectedItem})},_normalize:function(e){return e.length&&e[0].label&&e[0].value?e:t.map(e,function(e){return\"string\"==typeof e?{label:e,value:e}:t.extend({label:e.label||e.value,value:e.value||e.label},e)})},_suggest:function(e){var i=this.menu.element.empty();this._renderMenu(i,e),this.isNewMenu=!0,this.menu.refresh(),i.show(),this._resizeMenu(),i.position(t.extend({of:this.element},this.options.position)),this.options.autoFocus&&this.menu.next()},_resizeMenu:function(){var t=this.menu.element;t.outerWidth(Math.max(t.width(\"\").outerWidth()+1,this.element.outerWidth()))},_renderMenu:function(e,i){var s=this;t.each(i,function(t,i){s._renderItemData(e,i)})},_renderItemData:function(t,e){return this._renderItem(t,e).data(\"ui-autocomplete-item\",e)},_renderItem:function(e,i){return t(\"<li>\").append(t(\"<a>\").text(i.label)).appendTo(e)},_move:function(t,e){return this.menu.element.is(\":visible\")?this.menu.isFirstItem()&&/^previous/.test(t)||this.menu.isLastItem()&&/^next/.test(t)?(this._value(this.term),this.menu.blur(),undefined):(this.menu[t](e),undefined):(this.search(null,e),undefined)},widget:function(){return this.menu.element},_value:function(){return this.valueMethod.apply(this.element,arguments)},_keyEvent:function(t,e){(!this.isMultiLine||this.menu.element.is(\":visible\"))&&(this._move(t,e),e.preventDefault())}}),t.extend(t.ui.autocomplete,{escapeRegex:function(t){return t.replace(/[\\-\\[\\]{}()*+?.,\\\\\\^$|#\\s]/g,\"\\\\$&\")},filter:function(e,i){var s=RegExp(t.ui.autocomplete.escapeRegex(i),\"i\");return t.grep(e,function(t){return s.test(t.label||t.value||t)})}}),t.widget(\"ui.autocomplete\",t.ui.autocomplete,{options:{messages:{noResults:\"No search results.\",results:function(t){return t+(t>1?\" results are\":\" result is\")+\" available, use up and down arrow keys to navigate.\"}}},__response:function(t){var e;this._superApply(arguments),this.options.disabled||this.cancelSearch||(e=t&&t.length?this.options.messages.results(t.length):this.options.messages.noResults,this.liveRegion.text(e))}})}(jQuery),function(t){var e,i=\"ui-button ui-widget ui-state-default ui-corner-all\",s=\"ui-button-icons-only ui-button-icon-only ui-button-text-icons ui-button-text-icon-primary ui-button-text-icon-secondary ui-button-text-only\",n=function(){var e=t(this);setTimeout(function(){e.find(\":ui-button\").button(\"refresh\")},1)},o=function(e){var i=e.name,s=e.form,n=t([]);return i&&(i=i.replace(/'/g,\"\\\\'\"),n=s?t(s).find(\"[name='\"+i+\"']\"):t(\"[name='\"+i+\"']\",e.ownerDocument).filter(function(){return!this.form})),n};t.widget(\"ui.button\",{version:\"1.10.4\",defaultElement:\"<button>\",options:{disabled:null,text:!0,label:null,icons:{primary:null,secondary:null}},_create:function(){this.element.closest(\"form\").unbind(\"reset\"+this.eventNamespace).bind(\"reset\"+this.eventNamespace,n),\"boolean\"!=typeof this.options.disabled?this.options.disabled=!!this.element.prop(\"disabled\"):this.element.prop(\"disabled\",this.options.disabled),this._determineButtonType(),this.hasTitle=!!this.buttonElement.attr(\"title\");var s=this,a=this.options,r=\"checkbox\"===this.type||\"radio\"===this.type,h=r?\"\":\"ui-state-active\";null===a.label&&(a.label=\"input\"===this.type?this.buttonElement.val():this.buttonElement.html()),this._hoverable(this.buttonElement),this.buttonElement.addClass(i).attr(\"role\",\"button\").bind(\"mouseenter\"+this.eventNamespace,function(){a.disabled||this===e&&t(this).addClass(\"ui-state-active\")}).bind(\"mouseleave\"+this.eventNamespace,function(){a.disabled||t(this).removeClass(h)}).bind(\"click\"+this.eventNamespace,function(t){a.disabled&&(t.preventDefault(),t.stopImmediatePropagation())}),this._on({focus:function(){this.buttonElement.addClass(\"ui-state-focus\")},blur:function(){this.buttonElement.removeClass(\"ui-state-focus\")}}),r&&this.element.bind(\"change\"+this.eventNamespace,function(){s.refresh()}),\"checkbox\"===this.type?this.buttonElement.bind(\"click\"+this.eventNamespace,function(){return a.disabled?!1:undefined}):\"radio\"===this.type?this.buttonElement.bind(\"click\"+this.eventNamespace,function(){if(a.disabled)return!1;t(this).addClass(\"ui-state-active\"),s.buttonElement.attr(\"aria-pressed\",\"true\");var e=s.element[0];o(e).not(e).map(function(){return t(this).button(\"widget\")[0]}).removeClass(\"ui-state-active\").attr(\"aria-pressed\",\"false\")}):(this.buttonElement.bind(\"mousedown\"+this.eventNamespace,function(){return a.disabled?!1:(t(this).addClass(\"ui-state-active\"),e=this,s.document.one(\"mouseup\",function(){e=null}),undefined)}).bind(\"mouseup\"+this.eventNamespace,function(){return a.disabled?!1:(t(this).removeClass(\"ui-state-active\"),undefined)}).bind(\"keydown\"+this.eventNamespace,function(e){return a.disabled?!1:((e.keyCode===t.ui.keyCode.SPACE||e.keyCode===t.ui.keyCode.ENTER)&&t(this).addClass(\"ui-state-active\"),undefined)}).bind(\"keyup\"+this.eventNamespace+\" blur\"+this.eventNamespace,function(){t(this).removeClass(\"ui-state-active\")}),this.buttonElement.is(\"a\")&&this.buttonElement.keyup(function(e){e.keyCode===t.ui.keyCode.SPACE&&t(this).click()})),this._setOption(\"disabled\",a.disabled),this._resetButton()},_determineButtonType:function(){var t,e,i;this.type=this.element.is(\"[type=checkbox]\")?\"checkbox\":this.element.is(\"[type=radio]\")?\"radio\":this.element.is(\"input\")?\"input\":\"button\",\"checkbox\"===this.type||\"radio\"===this.type?(t=this.element.parents().last(),e=\"label[for='\"+this.element.attr(\"id\")+\"']\",this.buttonElement=t.find(e),this.buttonElement.length||(t=t.length?t.siblings():this.element.siblings(),this.buttonElement=t.filter(e),this.buttonElement.length||(this.buttonElement=t.find(e))),this.element.addClass(\"ui-helper-hidden-accessible\"),i=this.element.is(\":checked\"),i&&this.buttonElement.addClass(\"ui-state-active\"),this.buttonElement.prop(\"aria-pressed\",i)):this.buttonElement=this.element},widget:function(){return this.buttonElement},_destroy:function(){this.element.removeClass(\"ui-helper-hidden-accessible\"),this.buttonElement.removeClass(i+\" ui-state-active \"+s).removeAttr(\"role\").removeAttr(\"aria-pressed\").html(this.buttonElement.find(\".ui-button-text\").html()),this.hasTitle||this.buttonElement.removeAttr(\"title\")},_setOption:function(t,e){return this._super(t,e),\"disabled\"===t?(this.element.prop(\"disabled\",!!e),e&&this.buttonElement.removeClass(\"ui-state-focus\"),undefined):(this._resetButton(),undefined)},refresh:function(){var e=this.element.is(\"input, button\")?this.element.is(\":disabled\"):this.element.hasClass(\"ui-button-disabled\");e!==this.options.disabled&&this._setOption(\"disabled\",e),\"radio\"===this.type?o(this.element[0]).each(function(){t(this).is(\":checked\")?t(this).button(\"widget\").addClass(\"ui-state-active\").attr(\"aria-pressed\",\"true\"):t(this).button(\"widget\").removeClass(\"ui-state-active\").attr(\"aria-pressed\",\"false\")}):\"checkbox\"===this.type&&(this.element.is(\":checked\")?this.buttonElement.addClass(\"ui-state-active\").attr(\"aria-pressed\",\"true\"):this.buttonElement.removeClass(\"ui-state-active\").attr(\"aria-pressed\",\"false\"))},_resetButton:function(){if(\"input\"===this.type)return this.options.label&&this.element.val(this.options.label),undefined;var e=this.buttonElement.removeClass(s),i=t(\"<span></span>\",this.document[0]).addClass(\"ui-button-text\").html(this.options.label).appendTo(e.empty()).text(),n=this.options.icons,o=n.primary&&n.secondary,a=[];n.primary||n.secondary?(this.options.text&&a.push(\"ui-button-text-icon\"+(o?\"s\":n.primary?\"-primary\":\"-secondary\")),n.primary&&e.prepend(\"<span class='ui-button-icon-primary ui-icon \"+n.primary+\"'></span>\"),n.secondary&&e.append(\"<span class='ui-button-icon-secondary ui-icon \"+n.secondary+\"'></span>\"),this.options.text||(a.push(o?\"ui-button-icons-only\":\"ui-button-icon-only\"),this.hasTitle||e.attr(\"title\",t.trim(i)))):a.push(\"ui-button-text-only\"),e.addClass(a.join(\" \"))}}),t.widget(\"ui.buttonset\",{version:\"1.10.4\",options:{items:\"button, input[type=button], input[type=submit], input[type=reset], input[type=checkbox], input[type=radio], a, :data(ui-button)\"},_create:function(){this.element.addClass(\"ui-buttonset\")},_init:function(){this.refresh()},_setOption:function(t,e){\"disabled\"===t&&this.buttons.button(\"option\",t,e),this._super(t,e)},refresh:function(){var e=\"rtl\"===this.element.css(\"direction\");this.buttons=this.element.find(this.options.items).filter(\":ui-button\").button(\"refresh\").end().not(\":ui-button\").button().end().map(function(){return t(this).button(\"widget\")[0]}).removeClass(\"ui-corner-all ui-corner-left ui-corner-right\").filter(\":first\").addClass(e?\"ui-corner-right\":\"ui-corner-left\").end().filter(\":last\").addClass(e?\"ui-corner-left\":\"ui-corner-right\").end().end()},_destroy:function(){this.element.removeClass(\"ui-buttonset\"),this.buttons.map(function(){return t(this).button(\"widget\")[0]}).removeClass(\"ui-corner-left ui-corner-right\").end().button(\"destroy\")}})}(jQuery),function(t,e){function i(){this._curInst=null,this._keyEvent=!1,this._disabledInputs=[],this._datepickerShowing=!1,this._inDialog=!1,this._mainDivId=\"ui-datepicker-div\",this._inlineClass=\"ui-datepicker-inline\",this._appendClass=\"ui-datepicker-append\",this._triggerClass=\"ui-datepicker-trigger\",this._dialogClass=\"ui-datepicker-dialog\",this._disableClass=\"ui-datepicker-disabled\",this._unselectableClass=\"ui-datepicker-unselectable\",this._currentClass=\"ui-datepicker-current-day\",this._dayOverClass=\"ui-datepicker-days-cell-over\",this.regional=[],this.regional[\"\"]={closeText:\"Done\",prevText:\"Prev\",nextText:\"Next\",currentText:\"Today\",monthNames:[\"January\",\"February\",\"March\",\"April\",\"May\",\"June\",\"July\",\"August\",\"September\",\"October\",\"November\",\"December\"],monthNamesShort:[\"Jan\",\"Feb\",\"Mar\",\"Apr\",\"May\",\"Jun\",\"Jul\",\"Aug\",\"Sep\",\"Oct\",\"Nov\",\"Dec\"],dayNames:[\"Sunday\",\"Monday\",\"Tuesday\",\"Wednesday\",\"Thursday\",\"Friday\",\"Saturday\"],dayNamesShort:[\"Sun\",\"Mon\",\"Tue\",\"Wed\",\"Thu\",\"Fri\",\"Sat\"],dayNamesMin:[\"Su\",\"Mo\",\"Tu\",\"We\",\"Th\",\"Fr\",\"Sa\"],weekHeader:\"Wk\",dateFormat:\"mm/dd/yy\",firstDay:0,isRTL:!1,showMonthAfterYear:!1,yearSuffix:\"\"},this._defaults={showOn:\"focus\",showAnim:\"fadeIn\",showOptions:{},defaultDate:null,appendText:\"\",buttonText:\"...\",buttonImage:\"\",buttonImageOnly:!1,hideIfNoPrevNext:!1,navigationAsDateFormat:!1,gotoCurrent:!1,changeMonth:!1,changeYear:!1,yearRange:\"c-10:c+10\",showOtherMonths:!1,selectOtherMonths:!1,showWeek:!1,calculateWeek:this.iso8601Week,shortYearCutoff:\"+10\",minDate:null,maxDate:null,duration:\"fast\",beforeShowDay:null,beforeShow:null,onSelect:null,onChangeMonthYear:null,onClose:null,numberOfMonths:1,showCurrentAtPos:0,stepMonths:1,stepBigMonths:12,altField:\"\",altFormat:\"\",constrainInput:!0,showButtonPanel:!1,autoSize:!1,disabled:!1},t.extend(this._defaults,this.regional[\"\"]),this.dpDiv=s(t(\"<div id='\"+this._mainDivId+\"' class='ui-datepicker ui-widget ui-widget-content ui-helper-clearfix ui-corner-all'></div>\"))}function s(e){var i=\"button, .ui-datepicker-prev, .ui-datepicker-next, .ui-datepicker-calendar td a\";return e.delegate(i,\"mouseout\",function(){t(this).removeClass(\"ui-state-hover\"),-1!==this.className.indexOf(\"ui-datepicker-prev\")&&t(this).removeClass(\"ui-datepicker-prev-hover\"),-1!==this.className.indexOf(\"ui-datepicker-next\")&&t(this).removeClass(\"ui-datepicker-next-hover\")}).delegate(i,\"mouseover\",function(){t.datepicker._isDisabledDatepicker(o.inline?e.parent()[0]:o.input[0])||(t(this).parents(\".ui-datepicker-calendar\").find(\"a\").removeClass(\"ui-state-hover\"),t(this).addClass(\"ui-state-hover\"),-1!==this.className.indexOf(\"ui-datepicker-prev\")&&t(this).addClass(\"ui-datepicker-prev-hover\"),-1!==this.className.indexOf(\"ui-datepicker-next\")&&t(this).addClass(\"ui-datepicker-next-hover\"))})}function n(e,i){t.extend(e,i);for(var s in i)null==i[s]&&(e[s]=i[s]);");
            bufferedWriter.write("return e}t.extend(t.ui,{datepicker:{version:\"1.10.4\"}});var o,a=\"datepicker\";t.extend(i.prototype,{markerClassName:\"hasDatepicker\",maxRows:4,_widgetDatepicker:function(){return this.dpDiv},setDefaults:function(t){return n(this._defaults,t||{}),this},_attachDatepicker:function(e,i){var s,n,o;s=e.nodeName.toLowerCase(),n=\"div\"===s||\"span\"===s,e.id||(this.uuid+=1,e.id=\"dp\"+this.uuid),o=this._newInst(t(e),n),o.settings=t.extend({},i||{}),\"input\"===s?this._connectDatepicker(e,o):n&&this._inlineDatepicker(e,o)},_newInst:function(e,i){var n=e[0].id.replace(/([^A-Za-z0-9_\\-])/g,\"\\\\\\\\$1\");return{id:n,input:e,selectedDay:0,selectedMonth:0,selectedYear:0,drawMonth:0,drawYear:0,inline:i,dpDiv:i?s(t(\"<div class='\"+this._inlineClass+\" ui-datepicker ui-widget ui-widget-content ui-helper-clearfix ui-corner-all'></div>\")):this.dpDiv}},_connectDatepicker:function(e,i){var s=t(e);i.append=t([]),i.trigger=t([]),s.hasClass(this.markerClassName)||(this._attachments(s,i),s.addClass(this.markerClassName).keydown(this._doKeyDown).keypress(this._doKeyPress).keyup(this._doKeyUp),this._autoSize(i),t.data(e,a,i),i.settings.disabled&&this._disableDatepicker(e))},_attachments:function(e,i){var s,n,o,a=this._get(i,\"appendText\"),r=this._get(i,\"isRTL\");i.append&&i.append.remove(),a&&(i.append=t(\"<span class='\"+this._appendClass+\"'>\"+a+\"</span>\"),e[r?\"before\":\"after\"](i.append)),e.unbind(\"focus\",this._showDatepicker),i.trigger&&i.trigger.remove(),s=this._get(i,\"showOn\"),(\"focus\"===s||\"both\"===s)&&e.focus(this._showDatepicker),(\"button\"===s||\"both\"===s)&&(n=this._get(i,\"buttonText\"),o=this._get(i,\"buttonImage\"),i.trigger=t(this._get(i,\"buttonImageOnly\")?t(\"<img/>\").addClass(this._triggerClass).attr({src:o,alt:n,title:n}):t(\"<button type='button'></button>\").addClass(this._triggerClass).html(o?t(\"<img/>\").attr({src:o,alt:n,title:n}):n)),e[r?\"before\":\"after\"](i.trigger),i.trigger.click(function(){return t.datepicker._datepickerShowing&&t.datepicker._lastInput===e[0]?t.datepicker._hideDatepicker():t.datepicker._datepickerShowing&&t.datepicker._lastInput!==e[0]?(t.datepicker._hideDatepicker(),t.datepicker._showDatepicker(e[0])):t.datepicker._showDatepicker(e[0]),!1}))},_autoSize:function(t){if(this._get(t,\"autoSize\")&&!t.inline){var e,i,s,n,o=new Date(2009,11,20),a=this._get(t,\"dateFormat\");a.match(/[DM]/)&&(e=function(t){for(i=0,s=0,n=0;t.length>n;n++)t[n].length>i&&(i=t[n].length,s=n);return s},o.setMonth(e(this._get(t,a.match(/MM/)?\"monthNames\":\"monthNamesShort\"))),o.setDate(e(this._get(t,a.match(/DD/)?\"dayNames\":\"dayNamesShort\"))+20-o.getDay())),t.input.attr(\"size\",this._formatDate(t,o).length)}},_inlineDatepicker:function(e,i){var s=t(e);s.hasClass(this.markerClassName)||(s.addClass(this.markerClassName).append(i.dpDiv),t.data(e,a,i),this._setDate(i,this._getDefaultDate(i),!0),this._updateDatepicker(i),this._updateAlternate(i),i.settings.disabled&&this._disableDatepicker(e),i.dpDiv.css(\"display\",\"block\"))},_dialogDatepicker:function(e,i,s,o,r){var h,l,c,u,d,p=this._dialogInst;return p||(this.uuid+=1,h=\"dp\"+this.uuid,this._dialogInput=t(\"<input type='text' id='\"+h+\"' style='position: absolute; top: -100px; width: 0px;'/>\"),this._dialogInput.keydown(this._doKeyDown),t(\"body\").append(this._dialogInput),p=this._dialogInst=this._newInst(this._dialogInput,!1),p.settings={},t.data(this._dialogInput[0],a,p)),n(p.settings,o||{}),i=i&&i.constructor===Date?this._formatDate(p,i):i,this._dialogInput.val(i),this._pos=r?r.length?r:[r.pageX,r.pageY]:null,this._pos||(l=document.documentElement.clientWidth,c=document.documentElement.clientHeight,u=document.documentElement.scrollLeft||document.body.scrollLeft,d=document.documentElement.scrollTop||document.body.scrollTop,this._pos=[l/2-100+u,c/2-150+d]),this._dialogInput.css(\"left\",this._pos[0]+20+\"px\").css(\"top\",this._pos[1]+\"px\"),p.settings.onSelect=s,this._inDialog=!0,this.dpDiv.addClass(this._dialogClass),this._showDatepicker(this._dialogInput[0]),t.blockUI&&t.blockUI(this.dpDiv),t.data(this._dialogInput[0],a,p),this},_destroyDatepicker:function(e){var i,s=t(e),n=t.data(e,a);s.hasClass(this.markerClassName)&&(i=e.nodeName.toLowerCase(),t.removeData(e,a),\"input\"===i?(n.append.remove(),n.trigger.remove(),s.removeClass(this.markerClassName).unbind(\"focus\",this._showDatepicker).unbind(\"keydown\",this._doKeyDown).unbind(\"keypress\",this._doKeyPress).unbind(\"keyup\",this._doKeyUp)):(\"div\"===i||\"span\"===i)&&s.removeClass(this.markerClassName).empty())},_enableDatepicker:function(e){var i,s,n=t(e),o=t.data(e,a);n.hasClass(this.markerClassName)&&(i=e.nodeName.toLowerCase(),\"input\"===i?(e.disabled=!1,o.trigger.filter(\"button\").each(function(){this.disabled=!1}).end().filter(\"img\").css({opacity:\"1.0\",cursor:\"\"})):(\"div\"===i||\"span\"===i)&&(s=n.children(\".\"+this._inlineClass),s.children().removeClass(\"ui-state-disabled\"),s.find(\"select.ui-datepicker-month, select.ui-datepicker-year\").prop(\"disabled\",!1)),this._disabledInputs=t.map(this._disabledInputs,function(t){return t===e?null:t}))},_disableDatepicker:function(e){var i,s,n=t(e),o=t.data(e,a);n.hasClass(this.markerClassName)&&(i=e.nodeName.toLowerCase(),\"input\"===i?(e.disabled=!0,o.trigger.filter(\"button\").each(function(){this.disabled=!0}).end().filter(\"img\").css({opacity:\"0.5\",cursor:\"default\"})):(\"div\"===i||\"span\"===i)&&(s=n.children(\".\"+this._inlineClass),s.children().addClass(\"ui-state-disabled\"),s.find(\"select.ui-datepicker-month, select.ui-datepicker-year\").prop(\"disabled\",!0)),this._disabledInputs=t.map(this._disabledInputs,function(t){return t===e?null:t}),this._disabledInputs[this._disabledInputs.length]=e)},_isDisabledDatepicker:function(t){if(!t)return!1;for(var e=0;this._disabledInputs.length>e;e++)if(this._disabledInputs[e]===t)return!0;return!1},_getInst:function(e){try{return t.data(e,a)}catch(i){throw\"Missing instance data for this datepicker\"}},_optionDatepicker:function(i,s,o){var a,r,h,l,c=this._getInst(i);return 2===arguments.length&&\"string\"==typeof s?\"defaults\"===s?t.extend({},t.datepicker._defaults):c?\"all\"===s?t.extend({},c.settings):this._get(c,s):null:(a=s||{},\"string\"==typeof s&&(a={},a[s]=o),c&&(this._curInst===c&&this._hideDatepicker(),r=this._getDateDatepicker(i,!0),h=this._getMinMaxDate(c,\"min\"),l=this._getMinMaxDate(c,\"max\"),n(c.settings,a),null!==h&&a.dateFormat!==e&&a.minDate===e&&(c.settings.minDate=this._formatDate(c,h)),null!==l&&a.dateFormat!==e&&a.maxDate===e&&(c.settings.maxDate=this._formatDate(c,l)),\"disabled\"in a&&(a.disabled?this._disableDatepicker(i):this._enableDatepicker(i)),this._attachments(t(i),c),this._autoSize(c),this._setDate(c,r),this._updateAlternate(c),this._updateDatepicker(c)),e)},_changeDatepicker:function(t,e,i){this._optionDatepicker(t,e,i)},_refreshDatepicker:function(t){var e=this._getInst(t);e&&this._updateDatepicker(e)},_setDateDatepicker:function(t,e){var i=this._getInst(t);i&&(this._setDate(i,e),this._updateDatepicker(i),this._updateAlternate(i))},_getDateDatepicker:function(t,e){var i=this._getInst(t);return i&&!i.inline&&this._setDateFromField(i,e),i?this._getDate(i):null},_doKeyDown:function(e){var i,s,n,o=t.datepicker._getInst(e.target),a=!0,r=o.dpDiv.is(\".ui-datepicker-rtl\");if(o._keyEvent=!0,t.datepicker._datepickerShowing)switch(e.keyCode){case 9:t.datepicker._hideDatepicker(),a=!1;break;case 13:return n=t(\"td.\"+t.datepicker._dayOverClass+\":not(.\"+t.datepicker._currentClass+\")\",o.dpDiv),n[0]&&t.datepicker._selectDay(e.target,o.selectedMonth,o.selectedYear,n[0]),i=t.datepicker._get(o,\"onSelect\"),i?(s=t.datepicker._formatDate(o),i.apply(o.input?o.input[0]:null,[s,o])):t.datepicker._hideDatepicker(),!1;case 27:t.datepicker._hideDatepicker();break;case 33:t.datepicker._adjustDate(e.target,e.ctrlKey?-t.datepicker._get(o,\"stepBigMonths\"):-t.datepicker._get(o,\"stepMonths\"),\"M\");break;case 34:t.datepicker._adjustDate(e.target,e.ctrlKey?+t.datepicker._get(o,\"stepBigMonths\"):+t.datepicker._get(o,\"stepMonths\"),\"M\");\n" +
                    "break;case 35:(e.ctrlKey||e.metaKey)&&t.datepicker._clearDate(e.target),a=e.ctrlKey||e.metaKey;break;case 36:(e.ctrlKey||e.metaKey)&&t.datepicker._gotoToday(e.target),a=e.ctrlKey||e.metaKey;break;case 37:(e.ctrlKey||e.metaKey)&&t.datepicker._adjustDate(e.target,r?1:-1,\"D\"),a=e.ctrlKey||e.metaKey,e.originalEvent.altKey&&t.datepicker._adjustDate(e.target,e.ctrlKey?-t.datepicker._get(o,\"stepBigMonths\"):-t.datepicker._get(o,\"stepMonths\"),\"M\");break;case 38:(e.ctrlKey||e.metaKey)&&t.datepicker._adjustDate(e.target,-7,\"D\"),a=e.ctrlKey||e.metaKey;break;case 39:(e.ctrlKey||e.metaKey)&&t.datepicker._adjustDate(e.target,r?-1:1,\"D\"),a=e.ctrlKey||e.metaKey,e.originalEvent.altKey&&t.datepicker._adjustDate(e.target,e.ctrlKey?+t.datepicker._get(o,\"stepBigMonths\"):+t.datepicker._get(o,\"stepMonths\"),\"M\");break;case 40:(e.ctrlKey||e.metaKey)&&t.datepicker._adjustDate(e.target,7,\"D\"),a=e.ctrlKey||e.metaKey;break;default:a=!1}else 36===e.keyCode&&e.ctrlKey?t.datepicker._showDatepicker(this):a=!1;a&&(e.preventDefault(),e.stopPropagation())},_doKeyPress:function(i){var s,n,o=t.datepicker._getInst(i.target);return t.datepicker._get(o,\"constrainInput\")?(s=t.datepicker._possibleChars(t.datepicker._get(o,\"dateFormat\")),n=String.fromCharCode(null==i.charCode?i.keyCode:i.charCode),i.ctrlKey||i.metaKey||\" \">n||!s||s.indexOf(n)>-1):e},_doKeyUp:function(e){var i,s=t.datepicker._getInst(e.target);if(s.input.val()!==s.lastVal)try{i=t.datepicker.parseDate(t.datepicker._get(s,\"dateFormat\"),s.input?s.input.val():null,t.datepicker._getFormatConfig(s)),i&&(t.datepicker._setDateFromField(s),t.datepicker._updateAlternate(s),t.datepicker._updateDatepicker(s))}catch(n){}return!0},_showDatepicker:function(e){if(e=e.target||e,\"input\"!==e.nodeName.toLowerCase()&&(e=t(\"input\",e.parentNode)[0]),!t.datepicker._isDisabledDatepicker(e)&&t.datepicker._lastInput!==e){var i,s,o,a,r,h,l;i=t.datepicker._getInst(e),t.datepicker._curInst&&t.datepicker._curInst!==i&&(t.datepicker._curInst.dpDiv.stop(!0,!0),i&&t.datepicker._datepickerShowing&&t.datepicker._hideDatepicker(t.datepicker._curInst.input[0])),s=t.datepicker._get(i,\"beforeShow\"),o=s?s.apply(e,[e,i]):{},o!==!1&&(n(i.settings,o),i.lastVal=null,t.datepicker._lastInput=e,t.datepicker._setDateFromField(i),t.datepicker._inDialog&&(e.value=\"\"),t.datepicker._pos||(t.datepicker._pos=t.datepicker._findPos(e),t.datepicker._pos[1]+=e.offsetHeight),a=!1,t(e).parents().each(function(){return a|=\"fixed\"===t(this).css(\"position\"),!a}),r={left:t.datepicker._pos[0],top:t.datepicker._pos[1]},t.datepicker._pos=null,i.dpDiv.empty(),i.dpDiv.css({position:\"absolute\",display:\"block\",top:\"-1000px\"}),t.datepicker._updateDatepicker(i),r=t.datepicker._checkOffset(i,r,a),i.dpDiv.css({position:t.datepicker._inDialog&&t.blockUI?\"static\":a?\"fixed\":\"absolute\",display:\"none\",left:r.left+\"px\",top:r.top+\"px\"}),i.inline||(h=t.datepicker._get(i,\"showAnim\"),l=t.datepicker._get(i,\"duration\"),i.dpDiv.zIndex(t(e).zIndex()+1),t.datepicker._datepickerShowing=!0,t.effects&&t.effects.effect[h]?i.dpDiv.show(h,t.datepicker._get(i,\"showOptions\"),l):i.dpDiv[h||\"show\"](h?l:null),t.datepicker._shouldFocusInput(i)&&i.input.focus(),t.datepicker._curInst=i))}},_updateDatepicker:function(e){this.maxRows=4,o=e,e.dpDiv.empty().append(this._generateHTML(e)),this._attachHandlers(e),e.dpDiv.find(\".\"+this._dayOverClass+\" a\").mouseover();var i,s=this._getNumberOfMonths(e),n=s[1],a=17;e.dpDiv.removeClass(\"ui-datepicker-multi-2 ui-datepicker-multi-3 ui-datepicker-multi-4\").width(\"\"),n>1&&e.dpDiv.addClass(\"ui-datepicker-multi-\"+n).css(\"width\",a*n+\"em\"),e.dpDiv[(1!==s[0]||1!==s[1]?\"add\":\"remove\")+\"Class\"](\"ui-datepicker-multi\"),e.dpDiv[(this._get(e,\"isRTL\")?\"add\":\"remove\")+\"Class\"](\"ui-datepicker-rtl\"),e===t.datepicker._curInst&&t.datepicker._datepickerShowing&&t.datepicker._shouldFocusInput(e)&&e.input.focus(),e.yearshtml&&(i=e.yearshtml,setTimeout(function(){i===e.yearshtml&&e.yearshtml&&e.dpDiv.find(\"select.ui-datepicker-year:first\").replaceWith(e.yearshtml),i=e.yearshtml=null},0))},_shouldFocusInput:function(t){return t.input&&t.input.is(\":visible\")&&!t.input.is(\":disabled\")&&!t.input.is(\":focus\")},_checkOffset:function(e,i,s){var n=e.dpDiv.outerWidth(),o=e.dpDiv.outerHeight(),a=e.input?e.input.outerWidth():0,r=e.input?e.input.outerHeight():0,h=document.documentElement.clientWidth+(s?0:t(document).scrollLeft()),l=document.documentElement.clientHeight+(s?0:t(document).scrollTop());return i.left-=this._get(e,\"isRTL\")?n-a:0,i.left-=s&&i.left===e.input.offset().left?t(document).scrollLeft():0,i.top-=s&&i.top===e.input.offset().top+r?t(document).scrollTop():0,i.left-=Math.min(i.left,i.left+n>h&&h>n?Math.abs(i.left+n-h):0),i.top-=Math.min(i.top,i.top+o>l&&l>o?Math.abs(o+r):0),i},_findPos:function(e){for(var i,s=this._getInst(e),n=this._get(s,\"isRTL\");e&&(\"hidden\"===e.type||1!==e.nodeType||t.expr.filters.hidden(e));)e=e[n?\"previousSibling\":\"nextSibling\"];return i=t(e).offset(),[i.left,i.top]},_hideDatepicker:function(e){var i,s,n,o,r=this._curInst;!r||e&&r!==t.data(e,a)||this._datepickerShowing&&(i=this._get(r,\"showAnim\"),s=this._get(r,\"duration\"),n=function(){t.datepicker._tidyDialog(r)},t.effects&&(t.effects.effect[i]||t.effects[i])?r.dpDiv.hide(i,t.datepicker._get(r,\"showOptions\"),s,n):");
            bufferedWriter.write("r.dpDiv[\"slideDown\"===i?\"slideUp\":\"fadeIn\"===i?\"fadeOut\":\"hide\"](i?s:null,n),i||n(),this._datepickerShowing=!1,o=this._get(r,\"onClose\"),o&&o.apply(r.input?r.input[0]:null,[r.input?r.input.val():\"\",r]),this._lastInput=null,this._inDialog&&(this._dialogInput.css({position:\"absolute\",left:\"0\",top:\"-100px\"}),t.blockUI&&(t.unblockUI(),t(\"body\").append(this.dpDiv))),this._inDialog=!1)},_tidyDialog:function(t){t.dpDiv.removeClass(this._dialogClass).unbind(\".ui-datepicker-calendar\")},_checkExternalClick:function(e){if(t.datepicker._curInst){var i=t(e.target),s=t.datepicker._getInst(i[0]);(i[0].id!==t.datepicker._mainDivId&&0===i.parents(\"#\"+t.datepicker._mainDivId).length&&!i.hasClass(t.datepicker.markerClassName)&&!i.closest(\".\"+t.datepicker._triggerClass).length&&t.datepicker._datepickerShowing&&(!t.datepicker._inDialog||!t.blockUI)||i.hasClass(t.datepicker.markerClassName)&&t.datepicker._curInst!==s)&&t.datepicker._hideDatepicker()}},_adjustDate:function(e,i,s){var n=t(e),o=this._getInst(n[0]);this._isDisabledDatepicker(n[0])||(this._adjustInstDate(o,i+(\"M\"===s?this._get(o,\"showCurrentAtPos\"):0),s),this._updateDatepicker(o))},_gotoToday:function(e){var i,s=t(e),n=this._getInst(s[0]);this._get(n,\"gotoCurrent\")&&n.currentDay?(n.selectedDay=n.currentDay,n.drawMonth=n.selectedMonth=n.currentMonth,n.drawYear=n.selectedYear=n.currentYear):(i=new Date,n.selectedDay=i.getDate(),n.drawMonth=n.selectedMonth=i.getMonth(),n.drawYear=n.selectedYear=i.getFullYear()),this._notifyChange(n),this._adjustDate(s)},_selectMonthYear:function(e,i,s){var n=t(e),o=this._getInst(n[0]);o[\"selected\"+(\"M\"===s?\"Month\":\"Year\")]=o[\"draw\"+(\"M\"===s?\"Month\":\"Year\")]=parseInt(i.options[i.selectedIndex].value,10),this._notifyChange(o),this._adjustDate(n)},_selectDay:function(e,i,s,n){var o,a=t(e);t(n).hasClass(this._unselectableClass)||this._isDisabledDatepicker(a[0])||(o=this._getInst(a[0]),o.selectedDay=o.currentDay=t(\"a\",n).html(),o.selectedMonth=o.currentMonth=i,o.selectedYear=o.currentYear=s,this._selectDate(e,this._formatDate(o,o.currentDay,o.currentMonth,o.currentYear)))},_clearDate:function(e){var i=t(e);this._selectDate(i,\"\")},_selectDate:function(e,i){var s,n=t(e),o=this._getInst(n[0]);i=null!=i?i:this._formatDate(o),o.input&&o.input.val(i),this._updateAlternate(o),s=this._get(o,\"onSelect\"),s?s.apply(o.input?o.input[0]:null,[i,o]):o.input&&o.input.trigger(\"change\"),o.inline?this._updateDatepicker(o):(this._hideDatepicker(),this._lastInput=o.input[0],\"object\"!=typeof o.input[0]&&o.input.focus(),this._lastInput=null)},_updateAlternate:function(e){var i,s,n,o=this._get(e,\"altField\");o&&(i=this._get(e,\"altFormat\")||this._get(e,\"dateFormat\"),s=this._getDate(e),n=this.formatDate(i,s,this._getFormatConfig(e)),t(o).each(function(){t(this).val(n)}))},noWeekends:function(t){var e=t.getDay();return[e>0&&6>e,\"\"]},iso8601Week:function(t){var e,i=new Date(t.getTime());return i.setDate(i.getDate()+4-(i.getDay()||7)),e=i.getTime(),i.setMonth(0),i.setDate(1),Math.floor(Math.round((e-i)/864e5)/7)+1},parseDate:function(i,s,n){if(null==i||null==s)throw\"Invalid arguments\";if(s=\"object\"==typeof s?\"\"+s:s+\"\",\"\"===s)return null;var o,a,r,h,l=0,c=(n?n.shortYearCutoff:null)||this._defaults.shortYearCutoff,u=\"string\"!=typeof c?c:(new Date).getFullYear()%100+parseInt(c,10),d=(n?n.dayNamesShort:null)||this._defaults.dayNamesShort,p=(n?n.dayNames:null)||this._defaults.dayNames,f=(n?n.monthNamesShort:null)||this._defaults.monthNamesShort,g=(n?n.monthNames:null)||this._defaults.monthNames,m=-1,v=-1,_=-1,b=-1,y=!1,w=function(t){var e=i.length>o+1&&i.charAt(o+1)===t;return e&&o++,e},x=function(t){var e=w(t),i=\"@\"===t?14:\"!\"===t?20:\"y\"===t&&e?4:\"o\"===t?3:2,n=RegExp(\"^\\\\d{1,\"+i+\"}\"),o=s.substring(l).match(n);if(!o)throw\"Missing number at position \"+l;return l+=o[0].length,parseInt(o[0],10)},k=function(i,n,o){var a=-1,r=t.map(w(i)?o:n,function(t,e){return[[e,t]]}).sort(function(t,e){return-(t[1].length-e[1].length)});if(t.each(r,function(t,i){var n=i[1];return s.substr(l,n.length).toLowerCase()===n.toLowerCase()?(a=i[0],l+=n.length,!1):e}),-1!==a)return a+1;throw\"Unknown name at position \"+l},D=function(){if(s.charAt(l)!==i.charAt(o))throw\"Unexpected literal at position \"+l;l++};for(o=0;i.length>o;o++)if(y)\"'\"!==i.charAt(o)||w(\"'\")?D():y=!1;else switch(i.charAt(o)){case\"d\":_=x(\"d\");break;case\"D\":k(\"D\",d,p);break;case\"o\":b=x(\"o\");break;case\"m\":v=x(\"m\");break;case\"M\":v=k(\"M\",f,g);break;case\"y\":m=x(\"y\");break;case\"@\":h=new Date(x(\"@\")),m=h.getFullYear(),v=h.getMonth()+1,_=h.getDate();break;case\"!\":h=new Date((x(\"!\")-this._ticksTo1970)/1e4),m=h.getFullYear(),v=h.getMonth()+1,_=h.getDate();break;case\"'\":w(\"'\")?D():y=!0;break;default:D()}if(s.length>l&&(r=s.substr(l),!/^\\s+/.test(r)))throw\"Extra/unparsed characters found in date: \"+r;if(-1===m?m=(new Date).getFullYear():100>m&&(m+=(new Date).getFullYear()-(new Date).getFullYear()%100+(u>=m?0:-100)),b>-1)for(v=1,_=b;;){if(a=this._getDaysInMonth(m,v-1),a>=_)break;v++,_-=a}if(h=this._daylightSavingAdjust(new Date(m,v-1,_)),h.getFullYear()!==m||h.getMonth()+1!==v||h.getDate()!==_)throw\"Invalid date\";return h},ATOM:\"yy-mm-dd\",COOKIE:\"D, dd M yy\",ISO_8601:\"yy-mm-dd\",RFC_822:\"D, d M y\",RFC_850:\"DD, dd-M-y\",RFC_1036:\"D, d M y\",RFC_1123:\"D, d M yy\",RFC_2822:\"D, d M yy\",RSS:\"D, d M y\",TICKS:\"!\",TIMESTAMP:\"@\",W3C:\"yy-mm-dd\",_ticksTo1970:1e7*60*60*24*(718685+Math.floor(492.5)-Math.floor(19.7)+Math.floor(4.925)),formatDate:function(t,e,i){if(!e)return\"\";var s,n=(i?i.dayNamesShort:null)||this._defaults.dayNamesShort,o=(i?i.dayNames:null)||this._defaults.dayNames,a=(i?i.monthNamesShort:null)||this._defaults.monthNamesShort,r=(i?i.monthNames:null)||this._defaults.monthNames,h=function(e){var i=t.length>s+1&&t.charAt(s+1)===e;return i&&s++,i},l=function(t,e,i){var s=\"\"+e;if(h(t))for(;i>s.length;)s=\"0\"+s;return s},c=function(t,e,i,s){return h(t)?s[e]:i[e]},u=\"\",d=!1;if(e)for(s=0;t.length>s;s++)if(d)\"'\"!==t.charAt(s)||h(\"'\")?u+=t.charAt(s):d=!1;else switch(t.charAt(s)){case\"d\":u+=l(\"d\",e.getDate(),2);break;case\"D\":u+=c(\"D\",e.getDay(),n,o);break;case\"o\":u+=l(\"o\",Math.round((new Date(e.getFullYear(),e.getMonth(),e.getDate()).getTime()-new Date(e.getFullYear(),0,0).getTime())/864e5),3);break;case\"m\":u+=l(\"m\",e.getMonth()+1,2);break;case\"M\":u+=c(\"M\",e.getMonth(),a,r);break;case\"y\":u+=h(\"y\")?e.getFullYear():(10>e.getYear()%100?\"0\":\"\")+e.getYear()%100;break;case\"@\":u+=e.getTime();break;case\"!\":u+=1e4*e.getTime()+this._ticksTo1970;break;case\"'\":h(\"'\")?u+=\"'\":d=!0;break;default:u+=t.charAt(s)}return u},_possibleChars:function(t){var e,i=\"\",s=!1,n=function(i){var s=t.length>e+1&&t.charAt(e+1)===i;return s&&e++,s};for(e=0;t.length>e;e++)if(s)\"'\"!==t.charAt(e)||n(\"'\")?i+=t.charAt(e):s=!1;else switch(t.charAt(e)){case\"d\":case\"m\":case\"y\":case\"@\":i+=\"0123456789\";break;case\"D\":case\"M\":return null;case\"'\":n(\"'\")?i+=\"'\":s=!0;break;default:i+=t.charAt(e)}return i},_get:function(t,i){return t.settings[i]!==e?t.settings[i]:this._defaults[i]},_setDateFromField:function(t,e){if(t.input.val()!==t.lastVal){var i=this._get(t,\"dateFormat\"),s=t.lastVal=t.input?t.input.val():null,n=this._getDefaultDate(t),o=n,a=this._getFormatConfig(t);try{o=this.parseDate(i,s,a)||n}catch(r){s=e?\"\":s}t.selectedDay=o.getDate(),t.drawMonth=t.selectedMonth=o.getMonth(),t.drawYear=t.selectedYear=o.getFullYear(),t.currentDay=s?o.getDate():0,t.currentMonth=s?o.getMonth():0,t.currentYear=s?o.getFullYear():0,this._adjustInstDate(t)}},_getDefaultDate:function(t){return this._restrictMinMax(t,this._determineDate(t,this._get(t,\"defaultDate\"),new Date))},_determineDate:function(e,i,s){var n=function(t){var e=new Date;return e.setDate(e.getDate()+t),e},o=function(i){try{return t.datepicker.parseDate(t.datepicker._get(e,\"dateFormat\"),i,t.datepicker._getFormatConfig(e))}catch(s){}for(var n=(i.toLowerCase().match(/^c/)?t.datepicker._getDate(e):null)||new Date,o=n.getFullYear(),a=n.getMonth(),r=n.getDate(),h=/([+\\-]?[0-9]+)\\s*(d|D|w|W|m|M|y|Y)?/g,l=h.exec(i);l;){switch(l[2]||\"d\"){case\"d\":case\"D\":r+=parseInt(l[1],10);break;case\"w\":case\"W\":r+=7*parseInt(l[1],10);break;case\"m\":case\"M\":a+=parseInt(l[1],10),r=Math.min(r,t.datepicker._getDaysInMonth(o,a));break;case\"y\":case\"Y\":o+=parseInt(l[1],10),r=Math.min(r,t.datepicker._getDaysInMonth(o,a))}l=h.exec(i)}return new Date(o,a,r)},a=null==i||\"\"===i?s:\"string\"==typeof i?o(i):\"number\"==typeof i?isNaN(i)?s:n(i):new Date(i.getTime());return a=a&&\"Invalid Date\"==\"\"+a?s:a,a&&(a.setHours(0),a.setMinutes(0),a.setSeconds(0),a.setMilliseconds(0)),this._daylightSavingAdjust(a)},_daylightSavingAdjust:function(t){return t?(t.setHours(t.getHours()>12?t.getHours()+2:0),t):null},_setDate:function(t,e,i){var s=!e,n=t.selectedMonth,o=t.selectedYear,a=this._restrictMinMax(t,this._determineDate(t,e,new Date));t.selectedDay=t.currentDay=a.getDate(),t.drawMonth=t.selectedMonth=t.currentMonth=a.getMonth(),t.drawYear=t.selectedYear=t.currentYear=a.getFullYear(),n===t.selectedMonth&&o===t.selectedYear||i||this._notifyChange(t),this._adjustInstDate(t),t.input&&t.input.val(s?\"\":this._formatDate(t))},_getDate:function(t){var e=!t.currentYear||t.input&&\"\"===t.input.val()?null:this._daylightSavingAdjust(new Date(t.currentYear,t.currentMonth,t.currentDay));return e},_attachHandlers:function(e){var i=this._get(e,\"stepMonths\"),s=\"#\"+e.id.replace(/\\\\\\\\/g,\"\\\\\");e.dpDiv.find(\"[data-handler]\").map(function(){var e={prev:function(){t.datepicker._adjustDate(s,-i,\"M\")},next:function(){t.datepicker._adjustDate(s,+i,\"M\")},hide:function(){t.datepicker._hideDatepicker()},today:function(){t.datepicker._gotoToday(s)},selectDay:function(){return t.datepicker._selectDay(s,+this.getAttribute(\"data-month\"),+this.getAttribute(\"data-year\"),this),!1},selectMonth:function(){return t.datepicker._selectMonthYear(s,this,\"M\"),!1},selectYear:function(){return t.datepicker._selectMonthYear(s,this,\"Y\"),!1}};t(this).bind(this.getAttribute(\"data-event\"),e[this.getAttribute(\"data-handler\")])})},_generateHTML:function(t){var e,i,s,n,o,a,r,h,l,c,u,d,p,f,g,m,v,_,b,y,w,x,k,D,C,I,P,T,M,S,z,A,E,H,N,W,O,F,R,L=new Date,j=this._daylightSavingAdjust(new Date(L.getFullYear(),L.getMonth(),L.getDate())),Y=this._get(t,\"isRTL\"),B=this._get(t,\"showButtonPanel\"),V=this._get(t,\"hideIfNoPrevNext\"),K=this._get(t,\"navigationAsDateFormat\"),q=this._getNumberOfMonths(t),U=this._get(t,\"showCurrentAtPos\"),Q=this._get(t,\"stepMonths\"),X=1!==q[0]||1!==q[1],$=this._daylightSavingAdjust(t.currentDay?new Date(t.currentYear,t.currentMonth,t.currentDay):new Date(9999,9,9)),G=this._getMinMaxDate(t,\"min\"),J=this._getMinMaxDate(t,\"max\"),Z=t.drawMonth-U,te=t.drawYear;if(0>Z&&(Z+=12,te--),J)for(e=this._daylightSavingAdjust(new Date(J.getFullYear(),J.getMonth()-q[0]*q[1]+1,J.getDate())),e=G&&G>e?G:e;this._daylightSavingAdjust(new Date(te,Z,1))>e;)Z--,0>Z&&(Z=11,te--);for(t.drawMonth=Z,t.drawYear=te,i=this._get(t,\"prevText\"),i=K?this.formatDate(i,this._daylightSavingAdjust(new Date(te,Z-Q,1)),this._getFormatConfig(t)):i,s=this._canAdjustMonth(t,-1,te,Z)?\"<a class='ui-datepicker-prev ui-corner-all' data-handler='prev' data-event='click' title='\"+i+\"'><span class='ui-icon ui-icon-circle-triangle-\"+(Y?\"e\":\"w\")+\"'>\"+i+\"</span></a>\":V?\"\":\"<a class='ui-datepicker-prev ui-corner-all ui-state-disabled' title='\"+i+\"'><span class='ui-icon ui-icon-circle-triangle-\"+(Y?\"e\":\"w\")+\"'>\"+i+\"</span></a>\",n=this._get(t,\"nextText\"),n=K?this.formatDate(n,this._daylightSavingAdjust(new Date(te,Z+Q,1)),this._getFormatConfig(t)):n,o=this._canAdjustMonth(t,1,te,Z)?\"<a class='ui-datepicker-next ui-corner-all' data-handler='next' data-event='click' title='\"+n+\"'><span class='ui-icon ui-icon-circle-triangle-\"+(Y?\"w\":\"e\")+\"'>\"+n+\"</span></a>\":V?\"\":\"<a class='ui-datepicker-next ui-corner-all ui-state-disabled' title='\"+n+\"'><span class='ui-icon ui-icon-circle-triangle-\"+(Y?\"w\":\"e\")+\"'>\"+n+\"</span></a>\",a=this._get(t,\"currentText\"),r=this._get(t,\"gotoCurrent\")&&t.currentDay?$:j,a=K?this.formatDate(a,r,this._getFormatConfig(t)):a,h=t.inline?\"\":\"<button type='button' class='ui-datepicker-close ui-state-default ui-priority-primary ui-corner-all' data-handler='hide' data-event='click'>\"+this._get(t,\"closeText\")+\"</button>\",l=B?\"<div class='ui-datepicker-buttonpane ui-widget-content'>\"+(Y?h:\"\")+(this._isInRange(t,r)?\"<button type='button' class='ui-datepicker-current ui-state-default ui-priority-secondary ui-corner-all' data-handler='today' data-event='click'>\"+a+\"</button>\":\"\")+(Y?\"\":h)+\"</div>\":\"\",c=parseInt(this._get(t,\"firstDay\"),10),c=isNaN(c)?0:c,u=this._get(t,\"showWeek\"),d=this._get(t,\"dayNames\"),p=this._get(t,\"dayNamesMin\"),f=this._get(t,\"monthNames\"),g=this._get(t,\"monthNamesShort\"),m=this._get(t,\"beforeShowDay\"),v=this._get(t,\"showOtherMonths\"),_=this._get(t,\"selectOtherMonths\"),b=this._getDefaultDate(t),y=\"\",x=0;q[0]>x;x++){for(k=\"\",this.maxRows=4,D=0;q[1]>D;D++){if(C=this._daylightSavingAdjust(new Date(te,Z,t.selectedDay)),I=\" ui-corner-all\",P=\"\",X){if(P+=\"<div class='ui-datepicker-group\",q[1]>1)switch(D){case 0:P+=\" ui-datepicker-group-first\",I=\" ui-corner-\"+(Y?\"right\":\"left\");break;case q[1]-1:P+=\" ui-datepicker-group-last\",I=\" ui-corner-\"+(Y?\"left\":\"right\");break;default:P+=\" ui-datepicker-group-middle\",I=\"\"}P+=\"'>\"}for(P+=\"<div class='ui-datepicker-header ui-widget-header ui-helper-clearfix\"+I+\"'>\"+(/all|left/.test(I)&&0===x?Y?o:s:\"\")+(/all|right/.test(I)&&0===x?Y?s:o:\"\")+this._generateMonthYearHeader(t,Z,te,G,J,x>0||D>0,f,g)+\"</div><table class='ui-datepicker-calendar'><thead>\"+\"<tr>\",T=u?\"<th class='ui-datepicker-week-col'>\"+this._get(t,\"weekHeader\")+\"</th>\":\"\",w=0;7>w;w++)M=(w+c)%7,T+=\"<th\"+((w+c+6)%7>=5?\" class='ui-datepicker-week-end'\":\"\")+\">\"+\"<span title='\"+d[M]+\"'>\"+p[M]+\"</span></th>\";for(P+=T+\"</tr></thead><tbody>\",S=this._getDaysInMonth(te,Z),te===t.selectedYear&&Z===t.selectedMonth&&(t.selectedDay=Math.min(t.selectedDay,S)),z=(this._getFirstDayOfMonth(te,Z)-c+7)%7,A=Math.ceil((z+S)/7),E=X?this.maxRows>A?this.maxRows:A:A,this.maxRows=E,H=this._daylightSavingAdjust(new Date(te,Z,1-z)),N=0;E>N;N++){for(P+=\"<tr>\",W=u?\"<td class='ui-datepicker-week-col'>\"+this._get(t,\"calculateWeek\")(H)+\"</td>\":\"\",w=0;7>w;w++)O=m?m.apply(t.input?t.input[0]:null,[H]):[!0,\"\"],F=H.getMonth()!==Z,R=F&&!_||!O[0]||G&&G>H||J&&H>J,W+=\"<td class='\"+((w+c+6)%7>=5?\" ui-datepicker-week-end\":\"\")+(F?\" ui-datepicker-other-month\":\"\")+(H.getTime()===C.getTime()&&Z===t.selectedMonth&&t._keyEvent||b.getTime()===H.getTime()&&b.getTime()===C.getTime()?\" \"+this._dayOverClass:\"\")+(R?\" \"+this._unselectableClass+\" ui-state-disabled\":\"\")+(F&&!v?\"\":\" \"+O[1]+(H.getTime()===$.getTime()?\" \"+this._currentClass:\"\")+(H.getTime()===j.getTime()?\" ui-datepicker-today\":\"\"))+\"'\"+(F&&!v||!O[2]?\"\":\" title='\"+O[2].replace(/'/g,\"&#39;\")+\"'\")+(R?\"\":\" data-handler='selectDay' data-event='click' data-month='\"+H.getMonth()+\"' data-year='\"+H.getFullYear()+\"'\")+\">\"+(F&&!v?\"&#xa0;\":R?\"<span class='ui-state-default'>\"+H.getDate()+\"</span>\":\"<a class='ui-state-default\"+(H.getTime()===j.getTime()?\" ui-state-highlight\":\"\")+(H.getTime()===$.getTime()?\" ui-state-active\":\"\")+(F?\" ui-priority-secondary\":\"\")+\"' href='#'>\"+H.getDate()+\"</a>\")+\"</td>\",H.setDate(H.getDate()+1),H=this._daylightSavingAdjust(H);P+=W+\"</tr>\"}Z++,Z>11&&(Z=0,te++),P+=\"</tbody></table>\"+(X?\"</div>\"+(q[0]>0&&D===q[1]-1?\"<div class='ui-datepicker-row-break'></div>\":\"\"):\"\"),k+=P}y+=k}return y+=l,t._keyEvent=!1,y},_generateMonthYearHeader:function(t,e,i,s,n,o,a,r){var h,l,c,u,d,p,f,g,m=this._get(t,\"changeMonth\"),v=this._get(t,\"changeYear\"),_=this._get(t,\"showMonthAfterYear\"),b=\"<div class='ui-datepicker-title'>\",y=\"\";if(o||!m)y+=\"<span class='ui-datepicker-month'>\"+a[e]+\"</span>\";else{for(h=s&&s.getFullYear()===i,l=n&&n.getFullYear()===i,y+=\"<select class='ui-datepicker-month' data-handler='selectMonth' data-event='change'>\",c=0;12>c;c++)(!h||c>=s.getMonth())&&(!l||n.getMonth()>=c)&&(y+=\"<option value='\"+c+\"'\"+(c===e?\" selected='selected'\":\"\")+\">\"+r[c]+\"</option>\");y+=\"</select>\"}if(_||(b+=y+(!o&&m&&v?\"\":\"&#xa0;\")),!t.yearshtml)if(t.yearshtml=\"\",o||!v)b+=\"<span class='ui-datepicker-year'>\"+i+\"</span>\";else{for(u=this._get(t,\"yearRange\").split(\":\"),d=(new Date).getFullYear(),p=function(t){var e=t.match(/c[+\\-].*/)?i+parseInt(t.substring(1),10):t.match(/[+\\-].*/)?d+parseInt(t,10):parseInt(t,10);return isNaN(e)?d:e},f=p(u[0]),g=Math.max(f,p(u[1]||\"\")),f=s?Math.max(f,s.getFullYear()):f,g=n?Math.min(g,n.getFullYear()):g,t.yearshtml+=\"<select class='ui-datepicker-year' data-handler='selectYear' data-event='change'>\";g>=f;f++)t.yearshtml+=\"<option value='\"+f+\"'\"+(f===i?\" selected='selected'\":\"\")+\">\"+f+\"</option>\";t.yearshtml+=\"</select>\",b+=t.yearshtml,t.yearshtml=null}return b+=this._get(t,\"yearSuffix\"),_&&(b+=(!o&&m&&v?\"\":\"&#xa0;\")+y),b+=\"</div>\"},_adjustInstDate:function(t,e,i){var s=t.drawYear+(\"Y\"===i?e:0),n=t.drawMonth+(\"M\"===i?e:0),o=Math.min(t.selectedDay,this._getDaysInMonth(s,n))+(\"D\"===i?e:0),a=this._restrictMinMax(t,this._daylightSavingAdjust(new Date(s,n,o)));t.selectedDay=a.getDate(),t.drawMonth=t.selectedMonth=a.getMonth(),t.drawYear=t.selectedYear=a.getFullYear(),(\"M\"===i||\"Y\"===i)&&this._notifyChange(t)},_restrictMinMax:function(t,e){var i=this._getMinMaxDate(t,\"min\"),s=this._getMinMaxDate(t,\"max\"),n=i&&i>e?i:e;return s&&n>s?s:n},_notifyChange:function(t){var e=this._get(t,\"onChangeMonthYear\");e&&e.apply(t.input?t.input[0]:null,[t.selectedYear,t.selectedMonth+1,t])},_getNumberOfMonths:function(t){var e=this._get(t,\"numberOfMonths\");return null==e?[1,1]:\"number\"==typeof e?[1,e]:e},_getMinMaxDate:function(t,e){return this._determineDate(t,this._get(t,e+\"Date\"),null)},_getDaysInMonth:function(t,e){return 32-this._daylightSavingAdjust(new Date(t,e,32)).getDate()},_getFirstDayOfMonth:function(t,e){return new Date(t,e,1).getDay()},_canAdjustMonth:function(t,e,i,s){var n=this._getNumberOfMonths(t),o=this._daylightSavingAdjust(new Date(i,s+(0>e?e:n[0]*n[1]),1));return 0>e&&o.setDate(this._getDaysInMonth(o.getFullYear(),o.getMonth())),this._isInRange(t,o)},_isInRange:function(t,e){var i,s,n=this._getMinMaxDate(t,\"min\"),o=this._getMinMaxDate(t,\"max\"),a=null,r=null,h=this._get(t,\"yearRange\");return h&&(i=h.split(\":\"),s=(new Date).getFullYear(),a=parseInt(i[0],10),r=parseInt(i[1],10),i[0].match(/[+\\-].*/)&&(a+=s),i[1].match(/[+\\-].*/)&&(r+=s)),(!n||e.getTime()>=n.getTime())&&(!o||e.getTime()<=o.getTime())&&(!a||e.getFullYear()>=a)&&(!r||r>=e.getFullYear())},_getFormatConfig:function(t){var e=this._get(t,\"shortYearCutoff\");return e=\"string\"!=typeof e?e:(new Date).getFullYear()%100+parseInt(e,10),{shortYearCutoff:e,dayNamesShort:this._get(t,\"dayNamesShort\"),dayNames:this._get(t,\"dayNames\"),monthNamesShort:this._get(t,\"monthNamesShort\"),monthNames:this._get(t,\"monthNames\")}},_formatDate:function(t,e,i,s){e||(t.currentDay=t.selectedDay,t.currentMonth=t.selectedMonth,t.currentYear=t.selectedYear);var n=e?\"object\"==typeof e?e:this._daylightSavingAdjust(new Date(s,i,e)):this._daylightSavingAdjust(new Date(t.currentYear,t.currentMonth,t.currentDay));return this.formatDate(this._get(t,\"dateFormat\"),n,this._getFormatConfig(t))}}),t.fn.datepicker=function(e){if(!this.length)return this;t.datepicker.initialized||(t(document).mousedown(t.datepicker._checkExternalClick),t.datepicker.initialized=!0),0===t(\"#\"+t.datepicker._mainDivId).length&&t(\"body\").append(t.datepicker.dpDiv);var i=Array.prototype.slice.call(arguments,1);return\"string\"!=typeof e||\"isDisabled\"!==e&&\"getDate\"!==e&&\"widget\"!==e?\"option\"===e&&2===arguments.length&&\"string\"==typeof arguments[1]?t.datepicker[\"_\"+e+\"Datepicker\"].apply(t.datepicker,[this[0]].concat(i)):this.each(function(){\"string\"==typeof e?t.datepicker[\"_\"+e+\"Datepicker\"].apply(t.datepicker,[this].concat(i)):t.datepicker._attachDatepicker(this,e)}):t.datepicker[\"_\"+e+\"Datepicker\"].apply(t.datepicker,[this[0]].concat(i))},t.datepicker=new i,t.datepicker.initialized=!1,t.datepicker.uuid=(new Date).getTime(),t.datepicker.version=\"1.10.4\"}(jQuery),function(t){var e={buttons:!0,height:!0,maxHeight:!0,maxWidth:!0,minHeight:!0,minWidth:!0,width:!0},i={maxHeight:!0,maxWidth:!0,minHeight:!0,minWidth:!0};t.widget(\"ui.dialog\",{version:\"1.10.4\",options:{appendTo:\"body\",autoOpen:!0,buttons:[],closeOnEscape:!0,closeText:\"close\",dialogClass:\"\",draggable:!0,hide:null,height:\"auto\",maxHeight:null,maxWidth:null,minHeight:150,minWidth:150,modal:!1,position:{my:\"center\",at:\"center\",of:window,collision:\"fit\",using:function(e){var i=t(this).css(e).offset().top;0>i&&t(this).css(\"top\",e.top-i)}},resizable:!0,show:null,title:null,width:300,beforeClose:null,close:null,drag:null,dragStart:null,dragStop:null,focus:null,open:null,resize:null,resizeStart:null,resizeStop:null},_create:function(){this.originalCss={display:this.element[0].style.display,width:this.element[0].style.width,minHeight:this.element[0].style.minHeight,maxHeight:this.element[0].style.maxHeight,height:this.element[0].style.height},this.originalPosition={parent:this.element.parent(),index:this.element.parent().children().index(this.element)},this.originalTitle=this.element.attr(\"title\"),this.options.title=this.options.title||this.originalTitle,this._createWrapper(),this.element.show().removeAttr(\"title\").addClass(\"ui-dialog-content ui-widget-content\").appendTo(this.uiDialog),this._createTitlebar(),this._createButtonPane(),this.options.draggable&&t.fn.draggable&&this._makeDraggable(),this.options.resizable&&t.fn.resizable&&this._makeResizable(),this._isOpen=!1},_init:function(){this.options.autoOpen&&this.open()},_appendTo:function(){var e=this.options.appendTo;return e&&(e.jquery||e.nodeType)?t(e):this.document.find(e||\"body\").eq(0)},_destroy:function(){var t,e=this.originalPosition;this._destroyOverlay(),this.element.removeUniqueId().removeClass(\"ui-dialog-content ui-widget-content\").css(this.originalCss).detach(),this.uiDialog.stop(!0,!0).remove(),this.originalTitle&&this.element.attr(\"title\",this.originalTitle),t=e.parent.children().eq(e.index),t.length&&t[0]!==this.element[0]?t.before(this.element):e.parent.append(this.element)},widget:function(){return this.uiDialog},disable:t.noop,enable:t.noop,close:function(e){var i,s=this;if(this._isOpen&&this._trigger(\"beforeClose\",e)!==!1){if(this._isOpen=!1,this._destroyOverlay(),!this.opener.filter(\":focusable\").focus().length)try{i=this.document[0].activeElement,i&&\"body\"!==i.nodeName.toLowerCase()&&t(i).blur()}catch(n){}this._hide(this.uiDialog,this.options.hide,function(){s._trigger(\"close\",e)})}},isOpen:function(){return this._isOpen},moveToTop:function(){this._moveToTop()},_moveToTop:function(t,e){var i=!!this.uiDialog.nextAll(\":visible\").insertBefore(this.uiDialog).length;return i&&!e&&this._trigger(\"focus\",t),i},open:function(){var e=this;return this._isOpen?(this._moveToTop()&&this._focusTabbable(),undefined):(this._isOpen=!0,this.opener=t(this.document[0].activeElement),this._size(),this._position(),this._createOverlay(),this._moveToTop(null,!0),this._show(this.uiDialog,this.options.show,function(){e._focusTabbable(),e._trigger(\"focus\")}),this._trigger(\"open\"),undefined)},_focusTabbable:function(){var t=this.element.find(\"[autofocus]\");t.length||(t=this.element.find(\":tabbable\")),t.length||(t=this.uiDialogButtonPane.find(\":tabbable\")),t.length||(t=this.uiDialogTitlebarClose.filter(\":tabbable\")),t.length||(t=this.uiDialog),t.eq(0).focus()},_keepFocus:function(e){function i(){var e=this.document[0].activeElement,i=this.uiDialog[0]===e||t.contains(this.uiDialog[0],e);i||this._focusTabbable()}e.preventDefault(),i.call(this),this._delay(i)},_createWrapper:function(){this.uiDialog=t(\"<div>\").addClass(\"ui-dialog ui-widget ui-widget-content ui-corner-all ui-front \"+this.options.dialogClass).hide().attr({tabIndex:-1,role:\"dialog\"}).appendTo(this._appendTo()),this._on(this.uiDialog,{keydown:function(e){if(this.options.closeOnEscape&&!e.isDefaultPrevented()&&e.keyCode&&e.keyCode===t.ui.keyCode.ESCAPE)return e.preventDefault(),this.close(e),undefined;if(e.keyCode===t.ui.keyCode.TAB){var i=this.uiDialog.find(\":tabbable\"),s=i.filter(\":first\"),n=i.filter(\":last\");e.target!==n[0]&&e.target!==this.uiDialog[0]||e.shiftKey?e.target!==s[0]&&e.target!==this.uiDialog[0]||!e.shiftKey||(n.focus(1),e.preventDefault()):(s.focus(1),e.preventDefault())}},mousedown:function(t){this._moveToTop(t)&&this._focusTabbable()}}),this.element.find(\"[aria-describedby]\").length||this.uiDialog.attr({\"aria-describedby\":this.element.uniqueId().attr(\"id\")})},_createTitlebar:function(){var e;this.uiDialogTitlebar=t(\"<div>\").addClass(\"ui-dialog-titlebar ui-widget-header ui-corner-all ui-helper-clearfix\").prependTo(this.uiDialog),this._on(this.uiDialogTitlebar,{mousedown:function(e){t(e.target).closest(\".ui-dialog-titlebar-close\")||this.uiDialog.focus()}}),this.uiDialogTitlebarClose=t(\"<button type='button'></button>\").button({label:this.options.closeText,icons:{primary:\"ui-icon-closethick\"},text:!1}).addClass(\"ui-dialog-titlebar-close\").appendTo(this.uiDialogTitlebar),this._on(this.uiDialogTitlebarClose,{click:function(t){t.preventDefault(),this.close(t)}}),e=t(\"<span>\").uniqueId().addClass(\"ui-dialog-title\").prependTo(this.uiDialogTitlebar),this._title(e),this.uiDialog.attr({\"aria-labelledby\":e.attr(\"id\")})},_title:function(t){this.options.title||t.html(\"&#160;\"),t.text(this.options.title)},_createButtonPane:function(){this.uiDialogButtonPane=t(\"<div>\").addClass(\"ui-dialog-buttonpane ui-widget-content ui-helper-clearfix\"),this.uiButtonSet=t(\"<div>\").addClass(\"ui-dialog-buttonset\").appendTo(this.uiDialogButtonPane),this._createButtons()},_createButtons:function(){var e=this,i=this.options.buttons;return this.uiDialogButtonPane.remove(),this.uiButtonSet.empty(),t.isEmptyObject(i)||t.isArray(i)&&!i.length?(this.uiDialog.removeClass(\"ui-dialog-buttons\"),undefined):(t.each(i,function(i,s){var n,o;s=t.isFunction(s)?{click:s,text:i}:s,s=t.extend({type:\"button\"},s),n=s.click,s.click=function(){n.apply(e.element[0],arguments)},o={icons:s.icons,text:s.showText},delete s.icons,delete s.showText,t(\"<button></button>\",s).button(o).appendTo(e.uiButtonSet)}),this.uiDialog.addClass(\"ui-dialog-buttons\"),this.uiDialogButtonPane.appendTo(this.uiDialog),undefined)},_makeDraggable:function(){function e(t){return{position:t.position,offset:t.offset}}var i=this,s=this.options;this.uiDialog.draggable({cancel:\".ui-dialog-content, .ui-dialog-titlebar-close\",handle:\".ui-dialog-titlebar\",containment:\"document\",start:function(s,n){t(this).addClass(\"ui-dialog-dragging\"),i._blockFrames(),i._trigger(\"dragStart\",s,e(n))},drag:function(t,s){i._trigger(\"drag\",t,e(s))},stop:function(n,o){s.position=[o.position.left-i.document.scrollLeft(),o.position.top-i.document.scrollTop()],t(this).removeClass(\"ui-dialog-dragging\"),i._unblockFrames(),i._trigger(\"dragStop\",n,e(o))}})},_makeResizable:function(){function e(t){return{originalPosition:t.originalPosition,originalSize:t.originalSize,position:t.position,size:t.size}}var i=this,s=this.options,n=s.resizable,o=this.uiDialog.css(\"position\"),a=\"string\"==typeof n?n:\"n,e,s,w,se,sw,ne,nw\";\n" +
                    "this.uiDialog.resizable({cancel:\".ui-dialog-content\",containment:\"document\",alsoResize:this.element,maxWidth:s.maxWidth,maxHeight:s.maxHeight,minWidth:s.minWidth,minHeight:this._minHeight(),handles:a,start:function(s,n){t(this).addClass(\"ui-dialog-resizing\"),i._blockFrames(),i._trigger(\"resizeStart\",s,e(n))},resize:function(t,s){i._trigger(\"resize\",t,e(s))},stop:function(n,o){s.height=t(this).height(),s.width=t(this).width(),t(this).removeClass(\"ui-dialog-resizing\"),i._unblockFrames(),i._trigger(\"resizeStop\",n,e(o))}}).css(\"position\",o)},_minHeight:function(){var t=this.options;return\"auto\"===t.height?t.minHeight:Math.min(t.minHeight,t.height)},_position:function(){var t=this.uiDialog.is(\":visible\");t||this.uiDialog.show(),this.uiDialog.position(this.options.position),t||this.uiDialog.hide()},_setOptions:function(s){var n=this,o=!1,a={};t.each(s,function(t,s){n._setOption(t,s),t in e&&(o=!0),t in i&&(a[t]=s)}),o&&(this._size(),this._position()),this.uiDialog.is(\":data(ui-resizable)\")&&this.uiDialog.resizable(\"option\",a)},_setOption:function(t,e){var i,s,n=this.uiDialog;\"dialogClass\"===t&&n.removeClass(this.options.dialogClass).addClass(e),\"disabled\"!==t&&(this._super(t,e),\"appendTo\"===t&&this.uiDialog.appendTo(this._appendTo()),\"buttons\"===t&&this._createButtons(),\"closeText\"===t&&this.uiDialogTitlebarClose.button({label:\"\"+e}),\"draggable\"===t&&(i=n.is(\":data(ui-draggable)\"),i&&!e&&n.draggable(\"destroy\"),!i&&e&&this._makeDraggable()),\"position\"===t&&this._position(),\"resizable\"===t&&(s=n.is(\":data(ui-resizable)\"),s&&!e&&n.resizable(\"destroy\"),s&&\"string\"==typeof e&&n.resizable(\"option\",\"handles\",e),s||e===!1||this._makeResizable()),\"title\"===t&&this._title(this.uiDialogTitlebar.find(\".ui-dialog-title\")))},_size:function(){var t,e,i,s=this.options;this.element.show().css({width:\"auto\",minHeight:0,maxHeight:\"none\",height:0}),s.minWidth>s.width&&(s.width=s.minWidth),t=this.uiDialog.css({height:\"auto\",width:s.width}).outerHeight(),e=Math.max(0,s.minHeight-t),i=\"number\"==typeof s.maxHeight?Math.max(0,s.maxHeight-t):\"none\",\"auto\"===s.height?this.element.css({minHeight:e,maxHeight:i,height:\"auto\"}):this.element.height(Math.max(0,s.height-t)),this.uiDialog.is(\":data(ui-resizable)\")&&this.uiDialog.resizable(\"option\",\"minHeight\",this._minHeight())},_blockFrames:function(){this.iframeBlocks=this.document.find(\"iframe\").map(function(){var e=t(this);return t(\"<div>\").css({position:\"absolute\",width:e.outerWidth(),height:e.outerHeight()}).appendTo(e.parent()).offset(e.offset())[0]})},_unblockFrames:function(){this.iframeBlocks&&(this.iframeBlocks.remove(),delete this.iframeBlocks)},_allowInteraction:function(e){return t(e.target).closest(\".ui-dialog\").length?!0:!!t(e.target).closest(\".ui-datepicker\").length},_createOverlay:function(){if(this.options.modal){var e=this,i=this.widgetFullName;t.ui.dialog.overlayInstances||this._delay(function(){t.ui.dialog.overlayInstances&&this.document.bind(\"focusin.dialog\",function(s){e._allowInteraction(s)||(s.preventDefault(),t(\".ui-dialog:visible:last .ui-dialog-content\").data(i)._focusTabbable())})}),this.overlay=t(\"<div>\").addClass(\"ui-widget-overlay ui-front\").appendTo(this._appendTo()),this._on(this.overlay,{mousedown:\"_keepFocus\"}),t.ui.dialog.overlayInstances++}},_destroyOverlay:function(){this.options.modal&&this.overlay&&(t.ui.dialog.overlayInstances--,t.ui.dialog.overlayInstances||this.document.unbind(\"focusin.dialog\"),this.overlay.remove(),this.overlay=null)}}),t.ui.dialog.overlayInstances=0,t.uiBackCompat!==!1&&t.widget(\"ui.dialog\",t.ui.dialog,{_position:function(){var e,i=this.options.position,s=[],n=[0,0];i?((\"string\"==typeof i||\"object\"==typeof i&&\"0\"in i)&&(s=i.split?i.split(\" \"):[i[0],i[1]],1===s.length&&(s[1]=s[0]),t.each([\"left\",\"top\"],function(t,e){+s[t]===s[t]&&(n[t]=s[t],s[t]=e)}),i={my:s[0]+(0>n[0]?n[0]:\"+\"+n[0])+\" \"+s[1]+(0>n[1]?n[1]:\"+\"+n[1]),at:s.join(\" \")}),i=t.extend({},t.ui.dialog.prototype.options.position,i)):i=t.ui.dialog.prototype.options.position,e=this.uiDialog.is(\":visible\"),e||this.uiDialog.show(),this.uiDialog.position(i),e||this.uiDialog.hide()}})}(jQuery),function(t){var e=/up|down|vertical/,i=/up|left|vertical|horizontal/;t.effects.effect.blind=function(s,n){var o,a,r,h=t(this),l=[\"position\",\"top\",\"bottom\",\"left\",\"right\",\"height\",\"width\"],c=t.effects.setMode(h,s.mode||\"hide\"),u=s.direction||\"up\",d=e.test(u),p=d?\"height\":\"width\",f=d?\"top\":\"left\",g=i.test(u),m={},v=\"show\"===c;h.parent().is(\".ui-effects-wrapper\")?t.effects.save(h.parent(),l):t.effects.save(h,l),h.show(),o=t.effects.createWrapper(h).css({overflow:\"hidden\"}),a=o[p](),r=parseFloat(o.css(f))||0,m[p]=v?a:0,g||(h.css(d?\"bottom\":\"right\",0).css(d?\"top\":\"left\",\"auto\").css({position:\"absolute\"}),m[f]=v?r:a+r),v&&(o.css(p,0),g||o.css(f,r+a)),o.animate(m,{duration:s.duration,easing:s.easing,queue:!1,complete:function(){\"hide\"===c&&h.hide(),t.effects.restore(h,l),t.effects.removeWrapper(h),n()}})}}(jQuery),function(t){t.effects.effect.bounce=function(e,i){var s,n,o,a=t(this),r=[\"position\",\"top\",\"bottom\",\"left\",\"right\",\"height\",\"width\"],h=t.effects.setMode(a,e.mode||\"effect\"),l=\"hide\"===h,c=\"show\"===h,u=e.direction||\"up\",d=e.distance,p=e.times||5,f=2*p+(c||l?1:0),g=e.duration/f,m=e.easing,v=\"up\"===u||\"down\"===u?\"top\":\"left\",_=\"up\"===u||\"left\"===u,b=a.queue(),y=b.length;for((c||l)&&r.push(\"opacity\"),t.effects.save(a,r),a.show(),t.effects.createWrapper(a),d||(d=a[\"top\"===v?\"outerHeight\":\"outerWidth\"]()/3),c&&(o={opacity:1},o[v]=0,a.css(\"opacity\",0).css(v,_?2*-d:2*d).animate(o,g,m)),l&&(d/=Math.pow(2,p-1)),o={},o[v]=0,s=0;p>s;s++)n={},n[v]=(_?\"-=\":\"+=\")+d,a.animate(n,g,m).animate(o,g,m),d=l?2*d:d/2;l&&(n={opacity:0},n[v]=(_?\"-=\":\"+=\")+d,a.animate(n,g,m)),a.queue(function(){l&&a.hide(),t.effects.restore(a,r),t.effects.removeWrapper(a),i()}),y>1&&b.splice.apply(b,[1,0].concat(b.splice(y,f+1))),a.dequeue()}}(jQuery),function(t){t.effects.effect.clip=function(e,i){var s,n,o,a=t(this),r=[\"position\",\"top\",\"bottom\",\"left\",\"right\",\"height\",\"width\"],h=t.effects.setMode(a,e.mode||\"hide\"),l=\"show\"===h,c=e.direction||\"vertical\",u=\"vertical\"===c,d=u?\"height\":\"width\",p=u?\"top\":\"left\",f={};t.effects.save(a,r),a.show(),s=t.effects.createWrapper(a).css({overflow:\"hidden\"}),n=\"IMG\"===a[0].tagName?s:a,o=n[d](),l&&(n.css(d,0),n.css(p,o/2)),f[d]=l?o:0,f[p]=l?0:o/2,n.animate(f,{queue:!1,duration:e.duration,easing:e.easing,complete:function(){l||a.hide(),t.effects.restore(a,r),t.effects.removeWrapper(a),i()}})}}(jQuery),function(t){t.effects.effect.drop=function(e,i){var s,n=t(this),o=[\"position\",\"top\",\"bottom\",\"left\",\"right\",\"opacity\",\"height\",\"width\"],a=t.effects.setMode(n,e.mode||\"hide\"),r=\"show\"===a,h=e.direction||\"left\",l=\"up\"===h||\"down\"===h?\"top\":\"left\",c=\"up\"===h||\"left\"===h?\"pos\":\"neg\",u={opacity:r?1:0};t.effects.save(n,o),n.show(),t.effects.createWrapper(n),s=e.distance||n[\"top\"===l?\"outerHeight\":\"outerWidth\"](!0)/2,r&&n.css(\"opacity\",0).css(l,\"pos\"===c?-s:s),u[l]=(r?\"pos\"===c?\"+=\":\"-=\":\"pos\"===c?\"-=\":\"+=\")+s,n.animate(u,{queue:!1,duration:e.duration,easing:e.easing,complete:function(){\"hide\"===a&&n.hide(),t.effects.restore(n,o),t.effects.removeWrapper(n),i()}})}}(jQuery),function(t){t.effects.effect.explode=function(e,i){function s(){b.push(this),b.length===u*d&&n()}function n(){p.css({visibility:\"visible\"}),t(b).remove(),g||p.hide(),i()}var o,a,r,h,l,c,u=e.pieces?Math.round(Math.sqrt(e.pieces)):3,d=u,p=t(this),f=t.effects.setMode(p,e.mode||\"hide\"),g=\"show\"===f,m=p.show().css(\"visibility\",\"hidden\").offset(),v=Math.ceil(p.outerWidth()/d),_=Math.ceil(p.outerHeight()/u),b=[];for(o=0;u>o;o++)for(h=m.top+o*_,c=o-(u-1)/2,a=0;d>a;a++)r=m.left+a*v,l=a-(d-1)/2,p.clone().appendTo(\"body\").wrap(\"<div></div>\").css({position:\"absolute\",visibility:\"visible\",left:-a*v,top:-o*_}).parent().addClass(\"ui-effects-explode\").css({position:\"absolute\",overflow:\"hidden\",width:v,height:_,left:r+(g?l*v:0),top:h+(g?c*_:0),opacity:g?0:1}).animate({left:r+(g?0:l*v),top:h+(g?0:c*_),opacity:g?1:0},e.duration||500,e.easing,s)}}(jQuery),function(t){t.effects.effect.fade=function(e,i){var s=t(this),n=t.effects.setMode(s,e.mode||\"toggle\");s.animate({opacity:n},{queue:!1,duration:e.duration,easing:e.easing,complete:i})}}(jQuery),function(t){t.effects.effect.fold=function(e,i){var s,n,o=t(this),a=[\"position\",\"top\",\"bottom\",\"left\",\"right\",\"height\",\"width\"],r=t.effects.setMode(o,e.mode||\"hide\"),h=\"show\"===r,l=\"hide\"===r,c=e.size||15,u=/([0-9]+)%/.exec(c),d=!!e.horizFirst,p=h!==d,f=p?[\"width\",\"height\"]:[\"height\",\"width\"],g=e.duration/2,m={},v={};t.effects.save(o,a),o.show(),s=t.effects.createWrapper(o).css({overflow:\"hidden\"}),n=p?[s.width(),s.height()]:[s.height(),s.width()],u&&(c=parseInt(u[1],10)/100*n[l?0:1]),h&&s.css(d?{height:0,width:c}:{height:c,width:0}),m[f[0]]=h?n[0]:c,v[f[1]]=h?n[1]:0,s.animate(m,g,e.easing).animate(v,g,e.easing,function(){l&&o.hide(),t.effects.restore(o,a),t.effects.removeWrapper(o),i()})}}(jQuery),function(t){t.effects.effect.highlight=function(e,i){var s=t(this),n=[\"backgroundImage\",\"backgroundColor\",\"opacity\"],o=t.effects.setMode(s,e.mode||\"show\"),a={backgroundColor:s.css(\"backgroundColor\")};\"hide\"===o&&(a.opacity=0),t.effects.save(s,n),s.show().css({backgroundImage:\"none\",backgroundColor:e.color||\"#ffff99\"}).animate(a,{queue:!1,duration:e.duration,easing:e.easing,complete:function(){\"hide\"===o&&s.hide(),t.effects.restore(s,n),i()}})}}(jQuery),function(t){t.effects.effect.pulsate=function(e,i){var s,n=t(this),o=t.effects.setMode(n,e.mode||\"show\"),a=\"show\"===o,r=\"hide\"===o,h=a||\"hide\"===o,l=2*(e.times||5)+(h?1:0),c=e.duration/l,u=0,d=n.queue(),p=d.length;for((a||!n.is(\":visible\"))&&(n.css(\"opacity\",0).show(),u=1),s=1;l>s;s++)n.animate({opacity:u},c,e.easing),u=1-u;n.animate({opacity:u},c,e.easing),n.queue(function(){r&&n.hide(),i()}),p>1&&d.splice.apply(d,[1,0].concat(d.splice(p,l+1))),n.dequeue()}}(jQuery),function(t){t.effects.effect.puff=function(e,i){var s=t(this),n=t.effects.setMode(s,e.mode||\"hide\"),o=\"hide\"===n,a=parseInt(e.percent,10)||150,r=a/100,h={height:s.height(),width:s.width(),outerHeight:s.outerHeight(),outerWidth:s.outerWidth()};t.extend(e,{effect:\"scale\",queue:!1,fade:!0,mode:n,complete:i,percent:o?a:100,from:o?h:{height:h.height*r,width:h.width*r,outerHeight:h.outerHeight*r,outerWidth:h.outerWidth*r}}),s.effect(e)},t.effects.effect.scale=function(e,i){var s=t(this),n=t.extend(!0,{},e),o=t.effects.setMode(s,e.mode||\"effect\"),a=parseInt(e.percent,10)||(0===parseInt(e.percent,10)?0:\"hide\"===o?0:100),r=e.direction||\"both\",h=e.origin,l={height:s.height(),width:s.width(),outerHeight:s.outerHeight(),outerWidth:s.outerWidth()},c={y:\"horizontal\"!==r?a/100:1,x:\"vertical\"!==r?a/100:1};n.effect=\"size\",n.queue=!1,n.complete=i,\"effect\"!==o&&(n.origin=h||[\"middle\",\"center\"],n.restore=!0),n.from=e.from||(\"show\"===o?{height:0,width:0,outerHeight:0,outerWidth:0}:l),n.to={height:l.height*c.y,width:l.width*c.x,outerHeight:l.outerHeight*c.y,outerWidth:l.outerWidth*c.x},n.fade&&(\"show\"===o&&(n.from.opacity=0,n.to.opacity=1),\"hide\"===o&&(n.from.opacity=1,n.to.opacity=0)),s.effect(n)},t.effects.effect.size=function(e,i){var s,n,o,a=t(this),r=[\"position\",\"top\",\"bottom\",\"left\",\"right\",\"width\",\"height\",\"overflow\",\"opacity\"],h=[\"position\",\"top\",\"bottom\",\"left\",\"right\",\"overflow\",\"opacity\"],l=[\"width\",\"height\",\"overflow\"],c=[\"fontSize\"],u=[\"borderTopWidth\",\"borderBottomWidth\",\"paddingTop\",\"paddingBottom\"],d=[\"borderLeftWidth\",\"borderRightWidth\",\"paddingLeft\",\"paddingRight\"],p=t.effects.setMode(a,e.mode||\"effect\"),f=e.restore||\"effect\"!==p,g=e.scale||\"both\",m=e.origin||[\"middle\",\"center\"],v=a.css(\"position\"),_=f?r:h,b={height:0,width:0,outerHeight:0,outerWidth:0};\"show\"===p&&a.show(),s={height:a.height(),width:a.width(),outerHeight:a.outerHeight(),outerWidth:a.outerWidth()},\"toggle\"===e.mode&&\"show\"===p?(a.from=e.to||b,a.to=e.from||s):(a.from=e.from||(\"show\"===p?b:s),a.to=e.to||(\"hide\"===p?b:s)),o={from:{y:a.from.height/s.height,x:a.from.width/s.width},to:{y:a.to.height/s.height,x:a.to.width/s.width}},(\"box\"===g||\"both\"===g)&&(o.from.y!==o.to.y&&(_=_.concat(u),a.from=t.effects.setTransition(a,u,o.from.y,a.from),a.to=t.effects.setTransition(a,u,o.to.y,a.to)),o.from.x!==o.to.x&&(_=_.concat(d),a.from=t.effects.setTransition(a,d,o.from.x,a.from),a.to=t.effects.setTransition(a,d,o.to.x,a.to))),(\"content\"===g||\"both\"===g)&&o.from.y!==o.to.y&&(_=_.concat(c).concat(l),a.from=t.effects.setTransition(a,c,o.from.y,a.from),a.to=t.effects.setTransition(a,c,o.to.y,a.to)),t.effects.save(a,_),a.show(),t.effects.createWrapper(a),a.css(\"overflow\",\"hidden\").css(a.from),m&&(n=t.effects.getBaseline(m,s),a.from.top=(s.outerHeight-a.outerHeight())*n.y,a.from.left=(s.outerWidth-a.outerWidth())*n.x,a.to.top=(s.outerHeight-a.to.outerHeight)*n.y,a.to.left=(s.outerWidth-a.to.outerWidth)*n.x),a.css(a.from),(\"content\"===g||\"both\"===g)&&(u=u.concat([\"marginTop\",\"marginBottom\"]).concat(c),d=d.concat([\"marginLeft\",\"marginRight\"]),l=r.concat(u).concat(d),a.find(\"*[width]\").each(function(){var i=t(this),s={height:i.height(),width:i.width(),outerHeight:i.outerHeight(),outerWidth:i.outerWidth()};f&&t.effects.save(i,l),i.from={height:s.height*o.from.y,width:s.width*o.from.x,outerHeight:s.outerHeight*o.from.y,outerWidth:s.outerWidth*o.from.x},i.to={height:s.height*o.to.y,width:s.width*o.to.x,outerHeight:s.height*o.to.y,outerWidth:s.width*o.to.x},o.from.y!==o.to.y&&(i.from=t.effects.setTransition(i,u,o.from.y,i.from),i.to=t.effects.setTransition(i,u,o.to.y,i.to)),o.from.x!==o.to.x&&(i.from=t.effects.setTransition(i,d,o.from.x,i.from),i.to=t.effects.setTransition(i,d,o.to.x,i.to)),i.css(i.from),i.animate(i.to,e.duration,e.easing,function(){f&&t.effects.restore(i,l)})})),a.animate(a.to,{queue:!1,duration:e.duration,easing:e.easing,complete:function(){0===a.to.opacity&&a.css(\"opacity\",a.from.opacity),\"hide\"===p&&a.hide(),t.effects.restore(a,_),f||(\"static\"===v?a.css({position:\"relative\",top:a.to.top,left:a.to.left}):t.each([\"top\",\"left\"],function(t,e){a.css(e,function(e,i){var s=parseInt(i,10),n=t?a.to.left:a.to.top;return\"auto\"===i?n+\"px\":s+n+\"px\"})})),t.effects.removeWrapper(a),i()}})}}(jQuery),function(t){t.effects.effect.shake=function(e,i){var s,n=t(this),o=[\"position\",\"top\",\"bottom\",\"left\",\"right\",\"height\",\"width\"],a=t.effects.setMode(n,e.mode||\"effect\"),r=e.direction||\"left\",h=e.distance||20,l=e.times||3,c=2*l+1,u=Math.round(e.duration/c),d=\"up\"===r||\"down\"===r?\"top\":\"left\",p=\"up\"===r||\"left\"===r,f={},g={},m={},v=n.queue(),_=v.length;for(t.effects.save(n,o),n.show(),t.effects.createWrapper(n),f[d]=(p?\"-=\":\"+=\")+h,g[d]=(p?\"+=\":\"-=\")+2*h,m[d]=(p?\"-=\":\"+=\")+2*h,n.animate(f,u,e.easing),s=1;l>s;s++)n.animate(g,u,e.easing).animate(m,u,e.easing);n.animate(g,u,e.easing).animate(f,u/2,e.easing).queue(function(){\"hide\"===a&&n.hide(),t.effects.restore(n,o),t.effects.removeWrapper(n),i()}),_>1&&v.splice.apply(v,[1,0].concat(v.splice(_,c+1))),n.dequeue()}}(jQuery),function(t){t.effects.effect.slide=function(e,i){var s,n=t(this),o=[\"position\",\"top\",\"bottom\",\"left\",\"right\",\"width\",\"height\"],a=t.effects.setMode(n,e.mode||\"show\"),r=\"show\"===a,h=e.direction||\"left\",l=\"up\"===h||\"down\"===h?\"top\":\"left\",c=\"up\"===h||\"left\"===h,u={};t.effects.save(n,o),n.show(),s=e.distance||n[\"top\"===l?\"outerHeight\":\"outerWidth\"](!0),t.effects.createWrapper(n).css({overflow:\"hidden\"}),r&&n.css(l,c?isNaN(s)?\"-\"+s:-s:s),u[l]=(r?c?\"+=\":\"-=\":c?\"-=\":\"+=\")+s,n.animate(u,{queue:!1,duration:e.duration,easing:e.easing,complete:function(){\"hide\"===a&&n.hide(),t.effects.restore(n,o),t.effects.removeWrapper(n),i()}})}}(jQuery),function(t){t.effects.effect.transfer=function(e,i){var s=t(this),n=t(e.to),o=\"fixed\"===n.css(\"position\"),a=t(\"body\"),r=o?a.scrollTop():0,h=o?a.scrollLeft():0,l=n.offset(),c={top:l.top-r,left:l.left-h,height:n.innerHeight(),width:n.innerWidth()},u=s.offset(),d=t(\"<div class='ui-effects-transfer'></div>\").appendTo(document.body).addClass(e.className).css({top:u.top-r,left:u.left-h,height:s.innerHeight(),width:s.innerWidth(),position:o?\"fixed\":\"absolute\"}).animate(c,e.duration,e.easing,function(){d.remove(),i()})}}(jQuery),function(t){t.widget(\"ui.menu\",{version:\"1.10.4\",defaultElement:\"<ul>\",delay:300,options:{icons:{submenu:\"ui-icon-carat-1-e\"},menus:\"ul\",position:{my:\"left top\",at:\"right top\"},role:\"menu\",blur:null,focus:null,select:null},_create:function(){this.activeMenu=this.element,this.mouseHandled=!1,this.element.uniqueId().addClass(\"ui-menu ui-widget ui-widget-content ui-corner-all\").toggleClass(\"ui-menu-icons\",!!this.element.find(\".ui-icon\").length).attr({role:this.options.role,tabIndex:0}).bind(\"click\"+this.eventNamespace,t.proxy(function(t){this.options.disabled&&t.preventDefault()},this)),this.options.disabled&&this.element.addClass(\"ui-state-disabled\").attr(\"aria-disabled\",\"true\"),this._on({\"mousedown .ui-menu-item > a\":function(t){t.preventDefault()},\"click .ui-state-disabled > a\":function(t){t.preventDefault()},\"click .ui-menu-item:has(a)\":function(e){var i=t(e.target).closest(\".ui-menu-item\");!this.mouseHandled&&i.not(\".ui-state-disabled\").length&&(this.select(e),e.isPropagationStopped()||(this.mouseHandled=!0),i.has(\".ui-menu\").length?this.expand(e):!this.element.is(\":focus\")&&t(this.document[0].activeElement).closest(\".ui-menu\").length&&(this.element.trigger(\"focus\",[!0]),this.active&&1===this.active.parents(\".ui-menu\").length&&clearTimeout(this.timer)))},\"mouseenter .ui-menu-item\":function(e){var i=t(e.currentTarget);i.siblings().children(\".ui-state-active\").removeClass(\"ui-state-active\"),this.focus(e,i)},mouseleave:\"collapseAll\",\"mouseleave .ui-menu\":\"collapseAll\",focus:function(t,e){var i=this.active||this.element.children(\".ui-menu-item\").eq(0);e||this.focus(t,i)},blur:function(e){this._delay(function(){t.contains(this.element[0],this.document[0].activeElement)||this.collapseAll(e)})},keydown:\"_keydown\"}),this.refresh(),this._on(this.document,{click:function(e){t(e.target).closest(\".ui-menu\").length||this.collapseAll(e),this.mouseHandled=!1}})},_destroy:function(){this.element.removeAttr(\"aria-activedescendant\").find(\".ui-menu\").addBack().removeClass(\"ui-menu ui-widget ui-widget-content ui-corner-all ui-menu-icons\").removeAttr(\"role\").removeAttr(\"tabIndex\").removeAttr(\"aria-labelledby\").removeAttr(\"aria-expanded\").removeAttr(\"aria-hidden\").removeAttr(\"aria-disabled\").removeUniqueId().show(),this.element.find(\".ui-menu-item\").removeClass(\"ui-menu-item\").removeAttr(\"role\").removeAttr(\"aria-disabled\").children(\"a\").removeUniqueId().removeClass(\"ui-corner-all ui-state-hover\").removeAttr(\"tabIndex\").removeAttr(\"role\").removeAttr(\"aria-haspopup\").children().each(function(){var e=t(this);e.data(\"ui-menu-submenu-carat\")&&e.remove()}),this.element.find(\".ui-menu-divider\").removeClass(\"ui-menu-divider ui-widget-content\")},_keydown:function(e){function i(t){return t.replace(/[\\-\\[\\]{}()*+?.,\\\\\\^$|#\\s]/g,\"\\\\$&\")}var s,n,o,a,r,h=!0;switch(e.keyCode){case t.ui.keyCode.PAGE_UP:this.previousPage(e);break;case t.ui.keyCode.PAGE_DOWN:this.nextPage(e);break;case t.ui.keyCode.HOME:this._move(\"first\",\"first\",e);break;case t.ui.keyCode.END:this._move(\"last\",\"last\",e);break;case t.ui.keyCode.UP:this.previous(e);break;case t.ui.keyCode.DOWN:this.next(e);break;case t.ui.keyCode.LEFT:this.collapse(e);break;case t.ui.keyCode.RIGHT:this.active&&!this.active.is(\".ui-state-disabled\")&&this.expand(e);break;case t.ui.keyCode.ENTER:case t.ui.keyCode.SPACE:this._activate(e);break;case t.ui.keyCode.ESCAPE:this.collapse(e);break;default:h=!1,n=this.previousFilter||\"\",o=String.fromCharCode(e.keyCode),a=!1,clearTimeout(this.filterTimer),o===n?a=!0:o=n+o,r=RegExp(\"^\"+i(o),\"i\"),s=this.activeMenu.children(\".ui-menu-item\").filter(function(){return r.test(t(this).children(\"a\").text())}),s=a&&-1!==s.index(this.active.next())?this.active.nextAll(\".ui-menu-item\"):s,s.length||(o=String.fromCharCode(e.keyCode),r=RegExp(\"^\"+i(o),\"i\"),s=this.activeMenu.children(\".ui-menu-item\").filter(function(){return r.test(t(this).children(\"a\").text())})),s.length?(this.focus(e,s),s.length>1?(this.previousFilter=o,this.filterTimer=this._delay(function(){delete this.previousFilter},1e3)):delete this.previousFilter):delete this.previousFilter}h&&e.preventDefault()},_activate:function(t){this.active.is(\".ui-state-disabled\")||(this.active.children(\"a[aria-haspopup='true']\").length?this.expand(t):this.select(t))},refresh:function(){var e,i=this.options.icons.submenu,s=this.element.find(this.options.menus);this.element.toggleClass(\"ui-menu-icons\",!!this.element.find(\".ui-icon\").length),s.filter(\":not(.ui-menu)\").addClass(\"ui-menu ui-widget ui-widget-content ui-corner-all\").hide().attr({role:this.options.role,\"aria-hidden\":\"true\",\"aria-expanded\":\"false\"}).each(function(){var e=t(this),s=e.prev(\"a\"),n=t(\"<span>\").addClass(\"ui-menu-icon ui-icon \"+i).data(\"ui-menu-submenu-carat\",!0);s.attr(\"aria-haspopup\",\"true\").prepend(n),e.attr(\"aria-labelledby\",s.attr(\"id\"))}),e=s.add(this.element),e.children(\":not(.ui-menu-item):has(a)\").addClass(\"ui-menu-item\").attr(\"role\",\"presentation\").children(\"a\").uniqueId().addClass(\"ui-corner-all\").attr({tabIndex:-1,role:this._itemRole()}),e.children(\":not(.ui-menu-item)\").each(function(){var e=t(this);/[^\\-\\u2014\\u2013\\s]/.test(e.text())||e.addClass(\"ui-widget-content ui-menu-divider\")}),e.children(\".ui-state-disabled\").attr(\"aria-disabled\",\"true\"),this.active&&!t.contains(this.element[0],this.active[0])&&this.blur()},_itemRole:function(){return{menu:\"menuitem\",listbox:\"option\"}[this.options.role]},_setOption:function(t,e){\"icons\"===t&&this.element.find(\".ui-menu-icon\").removeClass(this.options.icons.submenu).addClass(e.submenu),this._super(t,e)},focus:function(t,e){var i,s;this.blur(t,t&&\"focus\"===t.type),this._scrollIntoView(e),this.active=e.first(),s=this.active.children(\"a\").addClass(\"ui-state-focus\"),this.options.role&&this.element.attr(\"aria-activedescendant\",s.attr(\"id\")),this.active.parent().closest(\".ui-menu-item\").children(\"a:first\").addClass(\"ui-state-active\"),t&&\"keydown\"===t.type?this._close():this.timer=this._delay(function(){this._close()},this.delay),i=e.children(\".ui-menu\"),i.length&&t&&/^mouse/.test(t.type)&&this._startOpening(i),this.activeMenu=e.parent(),this._trigger(\"focus\",t,{item:e})},_scrollIntoView:function(e){var i,s,n,o,a,r;this._hasScroll()&&(i=parseFloat(t.css(this.activeMenu[0],\"borderTopWidth\"))||0,s=parseFloat(t.css(this.activeMenu[0],\"paddingTop\"))||0,n=e.offset().top-this.activeMenu.offset().top-i-s,o=this.activeMenu.scrollTop(),a=this.activeMenu.height(),r=e.height(),0>n?this.activeMenu.scrollTop(o+n):n+r>a&&this.activeMenu.scrollTop(o+n-a+r))},blur:function(t,e){e||clearTimeout(this.timer),this.active&&(this.active.children(\"a\").removeClass(\"ui-state-focus\"),this.active=null,this._trigger(\"blur\",t,{item:this.active}))},_startOpening:function(t){clearTimeout(this.timer),\"true\"===t.attr(\"aria-hidden\")&&(this.timer=this._delay(function(){this._close(),this._open(t)},this.delay))},_open:function(e){var i=t.extend({of:this.active},this.options.position);clearTimeout(this.timer),this.element.find(\".ui-menu\").not(e.parents(\".ui-menu\")).hide().attr(\"aria-hidden\",\"true\"),e.show().removeAttr(\"aria-hidden\").attr(\"aria-expanded\",\"true\").position(i)},collapseAll:function(e,i){clearTimeout(this.timer),this.timer=this._delay(function(){var s=i?this.element:t(e&&e.target).closest(this.element.find(\".ui-menu\"));s.length||(s=this.element),this._close(s),this.blur(e),this.activeMenu=s},this.delay)},_close:function(t){t||(t=this.active?this.active.parent():this.element),t.find(\".ui-menu\").hide().attr(\"aria-hidden\",\"true\").attr(\"aria-expanded\",\"false\").end().find(\"a.ui-state-active\").removeClass(\"ui-state-active\")},collapse:function(t){var e=this.active&&this.active.parent().closest(\".ui-menu-item\",this.element);e&&e.length&&(this._close(),this.focus(t,e))},expand:function(t){var e=this.active&&this.active.children(\".ui-menu \").children(\".ui-menu-item\").first();e&&e.length&&(this._open(e.parent()),this._delay(function(){this.focus(t,e)}))},next:function(t){this._move(\"next\",\"first\",t)},previous:function(t){this._move(\"prev\",\"last\",t)},isFirstItem:function(){return this.active&&!this.active.prevAll(\".ui-menu-item\").length},isLastItem:function(){return this.active&&!this.active.nextAll(\".ui-menu-item\").length},_move:function(t,e,i){var s;this.active&&(s=\"first\"===t||\"last\"===t?this.active[\"first\"===t?\"prevAll\":\"nextAll\"](\".ui-menu-item\").eq(-1):this.active[t+\"All\"](\".ui-menu-item\").eq(0)),s&&s.length&&this.active||(s=this.activeMenu.children(\".ui-menu-item\")[e]()),this.focus(i,s)},nextPage:function(e){var i,s,n;return this.active?(this.isLastItem()||(this._hasScroll()?(s=this.active.offset().top,n=this.element.height(),this.active.nextAll(\".ui-menu-item\").each(function(){return i=t(this),0>i.offset().top-s-n}),this.focus(e,i)):this.focus(e,this.activeMenu.children(\".ui-menu-item\")[this.active?\"last\":\"first\"]())),undefined):(this.next(e),undefined)},previousPage:function(e){var i,s,n;return this.active?(this.isFirstItem()||(this._hasScroll()?(s=this.active.offset().top,n=this.element.height(),this.active.prevAll(\".ui-menu-item\").each(function(){return i=t(this),i.offset().top-s+n>0}),this.focus(e,i)):this.focus(e,this.activeMenu.children(\".ui-menu-item\").first())),undefined):(this.next(e),undefined)},_hasScroll:function(){return this.element.outerHeight()<this.element.prop(\"scrollHeight\")},select:function(e){this.active=this.active||t(e.target).closest(\".ui-menu-item\");var i={item:this.active};this.active.has(\".ui-menu\").length||this.collapseAll(e,!0),this._trigger(\"select\",e,i)}})}(jQuery),function(t,e){function i(t,e,i){return[parseFloat(t[0])*(p.test(t[0])?e/100:1),parseFloat(t[1])*(p.test(t[1])?i/100:1)]}function s(e,i){return parseInt(t.css(e,i),10)||0}function n(e){var i=e[0];return 9===i.nodeType?{width:e.width(),height:e.height(),offset:{top:0,left:0}}:t.isWindow(i)?{width:e.width(),height:e.height(),offset:{top:e.scrollTop(),left:e.scrollLeft()}}:i.preventDefault?{width:0,height:0,offset:{top:i.pageY,left:i.pageX}}:{width:e.outerWidth(),height:e.outerHeight(),offset:e.offset()}}t.ui=t.ui||{};var o,a=Math.max,r=Math.abs,h=Math.round,l=/left|center|right/,c=/top|center|bottom/,u=/[\\+\\-]\\d+(\\.[\\d]+)?%?/,d=/^\\w+/,p=/%$/,f=t.fn.position;t.position={scrollbarWidth:function(){if(o!==e)return o;var i,s,n=t(\"<div style='display:block;position:absolute;width:50px;height:50px;overflow:hidden;'><div style='height:100px;width:auto;'></div></div>\"),a=n.children()[0];return t(\"body\").append(n),i=a.offsetWidth,n.css(\"overflow\",\"scroll\"),s=a.offsetWidth,i===s&&(s=n[0].clientWidth),n.remove(),o=i-s},getScrollInfo:function(e){var i=e.isWindow||e.isDocument?\"\":e.element.css(\"overflow-x\"),s=e.isWindow||e.isDocument?\"\":e.element.css(\"overflow-y\"),n=\"scroll\"===i||\"auto\"===i&&e.width<e.element[0].scrollWidth,o=\"scroll\"===s||\"auto\"===s&&e.height<e.element[0].scrollHeight;return{width:o?t.position.scrollbarWidth():0,height:n?t.position.scrollbarWidth():0}},getWithinInfo:function(e){var i=t(e||window),s=t.isWindow(i[0]),n=!!i[0]&&9===i[0].nodeType;return{element:i,isWindow:s,isDocument:n,offset:i.offset()||{left:0,top:0},scrollLeft:i.scrollLeft(),scrollTop:i.scrollTop(),width:s?i.width():i.outerWidth(),height:s?i.height():i.outerHeight()}}},t.fn.position=function(e){if(!e||!e.of)return f.apply(this,arguments);e=t.extend({},e);var o,p,g,m,v,_,b=t(e.of),y=t.position.getWithinInfo(e.within),w=t.position.getScrollInfo(y),x=(e.collision||\"flip\").split(\" \"),k={};return _=n(b),b[0].preventDefault&&(e.at=\"left top\"),p=_.width,g=_.height,m=_.offset,v=t.extend({},m),t.each([\"my\",\"at\"],function(){var t,i,s=(e[this]||\"\").split(\" \");1===s.length&&(s=l.test(s[0])?s.concat([\"center\"]):c.test(s[0])?[\"center\"].concat(s):[\"center\",\"center\"]),s[0]=l.test(s[0])?s[0]:\"center\",s[1]=c.test(s[1])?s[1]:\"center\",t=u.exec(s[0]),i=u.exec(s[1]),k[this]=[t?t[0]:0,i?i[0]:0],e[this]=[d.exec(s[0])[0],d.exec(s[1])[0]]}),1===x.length&&(x[1]=x[0]),\"right\"===e.at[0]?v.left+=p:\"center\"===e.at[0]&&(v.left+=p/2),\"bottom\"===e.at[1]?v.top+=g:\"center\"===e.at[1]&&(v.top+=g/2),o=i(k.at,p,g),v.left+=o[0],v.top+=o[1],this.each(function(){var n,l,c=t(this),u=c.outerWidth(),d=c.outerHeight(),f=s(this,\"marginLeft\"),_=s(this,\"marginTop\"),D=u+f+s(this,\"marginRight\")+w.width,C=d+_+s(this,\"marginBottom\")+w.height,I=t.extend({},v),P=i(k.my,c.outerWidth(),c.outerHeight());\"right\"===e.my[0]?I.left-=u:\"center\"===e.my[0]&&(I.left-=u/2),\"bottom\"===e.my[1]?I.top-=d:\"center\"===e.my[1]&&(I.top-=d/2),I.left+=P[0],I.top+=P[1],t.support.offsetFractions||(I.left=h(I.left),I.top=h(I.top)),n={marginLeft:f,marginTop:_},t.each([\"left\",\"top\"],function(i,s){t.ui.position[x[i]]&&t.ui.position[x[i]][s](I,{targetWidth:p,targetHeight:g,elemWidth:u,elemHeight:d,collisionPosition:n,collisionWidth:D,collisionHeight:C,offset:[o[0]+P[0],o[1]+P[1]],my:e.my,at:e.at,within:y,elem:c})}),e.using&&(l=function(t){var i=m.left-I.left,s=i+p-u,n=m.top-I.top,o=n+g-d,h={target:{element:b,left:m.left,top:m.top,width:p,height:g},element:{element:c,left:I.left,top:I.top,width:u,height:d},horizontal:0>s?\"left\":i>0?\"right\":\"center\",vertical:0>o?\"top\":n>0?\"bottom\":\"middle\"};");
            bufferedWriter.write("u>p&&p>r(i+s)&&(h.horizontal=\"center\"),d>g&&g>r(n+o)&&(h.vertical=\"middle\"),h.important=a(r(i),r(s))>a(r(n),r(o))?\"horizontal\":\"vertical\",e.using.call(this,t,h)}),c.offset(t.extend(I,{using:l}))})},t.ui.position={fit:{left:function(t,e){var i,s=e.within,n=s.isWindow?s.scrollLeft:s.offset.left,o=s.width,r=t.left-e.collisionPosition.marginLeft,h=n-r,l=r+e.collisionWidth-o-n;e.collisionWidth>o?h>0&&0>=l?(i=t.left+h+e.collisionWidth-o-n,t.left+=h-i):t.left=l>0&&0>=h?n:h>l?n+o-e.collisionWidth:n:h>0?t.left+=h:l>0?t.left-=l:t.left=a(t.left-r,t.left)},top:function(t,e){var i,s=e.within,n=s.isWindow?s.scrollTop:s.offset.top,o=e.within.height,r=t.top-e.collisionPosition.marginTop,h=n-r,l=r+e.collisionHeight-o-n;e.collisionHeight>o?h>0&&0>=l?(i=t.top+h+e.collisionHeight-o-n,t.top+=h-i):t.top=l>0&&0>=h?n:h>l?n+o-e.collisionHeight:n:h>0?t.top+=h:l>0?t.top-=l:t.top=a(t.top-r,t.top)}},flip:{left:function(t,e){var i,s,n=e.within,o=n.offset.left+n.scrollLeft,a=n.width,h=n.isWindow?n.scrollLeft:n.offset.left,l=t.left-e.collisionPosition.marginLeft,c=l-h,u=l+e.collisionWidth-a-h,d=\"left\"===e.my[0]?-e.elemWidth:\"right\"===e.my[0]?e.elemWidth:0,p=\"left\"===e.at[0]?e.targetWidth:\"right\"===e.at[0]?-e.targetWidth:0,f=-2*e.offset[0];0>c?(i=t.left+d+p+f+e.collisionWidth-a-o,(0>i||r(c)>i)&&(t.left+=d+p+f)):u>0&&(s=t.left-e.collisionPosition.marginLeft+d+p+f-h,(s>0||u>r(s))&&(t.left+=d+p+f))},top:function(t,e){var i,s,n=e.within,o=n.offset.top+n.scrollTop,a=n.height,h=n.isWindow?n.scrollTop:n.offset.top,l=t.top-e.collisionPosition.marginTop,c=l-h,u=l+e.collisionHeight-a-h,d=\"top\"===e.my[1],p=d?-e.elemHeight:\"bottom\"===e.my[1]?e.elemHeight:0,f=\"top\"===e.at[1]?e.targetHeight:\"bottom\"===e.at[1]?-e.targetHeight:0,g=-2*e.offset[1];0>c?(s=t.top+p+f+g+e.collisionHeight-a-o,t.top+p+f+g>c&&(0>s||r(c)>s)&&(t.top+=p+f+g)):u>0&&(i=t.top-e.collisionPosition.marginTop+p+f+g-h,t.top+p+f+g>u&&(i>0||u>r(i))&&(t.top+=p+f+g))}},flipfit:{left:function(){t.ui.position.flip.left.apply(this,arguments),t.ui.position.fit.left.apply(this,arguments)},top:function(){t.ui.position.flip.top.apply(this,arguments),t.ui.position.fit.top.apply(this,arguments)}}},function(){var e,i,s,n,o,a=document.getElementsByTagName(\"body\")[0],r=document.createElement(\"div\");e=document.createElement(a?\"div\":\"body\"),s={visibility:\"hidden\",width:0,height:0,border:0,margin:0,background:\"none\"},a&&t.extend(s,{position:\"absolute\",left:\"-1000px\",top:\"-1000px\"});for(o in s)e.style[o]=s[o];e.appendChild(r),i=a||document.documentElement,i.insertBefore(e,i.firstChild),r.style.cssText=\"position: absolute; left: 10.7432222px;\",n=t(r).offset().left,t.support.offsetFractions=n>10&&11>n,e.innerHTML=\"\",i.removeChild(e)}()}(jQuery),function(t,e){t.widget(\"ui.progressbar\",{version:\"1.10.4\",options:{max:100,value:0,change:null,complete:null},min:0,_create:function(){this.oldValue=this.options.value=this._constrainedValue(),this.element.addClass(\"ui-progressbar ui-widget ui-widget-content ui-corner-all\").attr({role:\"progressbar\",\"aria-valuemin\":this.min}),this.valueDiv=t(\"<div class='ui-progressbar-value ui-widget-header ui-corner-left'></div>\").appendTo(this.element),this._refreshValue()\n" +
                    "},_destroy:function(){this.element.removeClass(\"ui-progressbar ui-widget ui-widget-content ui-corner-all\").removeAttr(\"role\").removeAttr(\"aria-valuemin\").removeAttr(\"aria-valuemax\").removeAttr(\"aria-valuenow\"),this.valueDiv.remove()},value:function(t){return t===e?this.options.value:(this.options.value=this._constrainedValue(t),this._refreshValue(),e)},_constrainedValue:function(t){return t===e&&(t=this.options.value),this.indeterminate=t===!1,\"number\"!=typeof t&&(t=0),this.indeterminate?!1:Math.min(this.options.max,Math.max(this.min,t))},_setOptions:function(t){var e=t.value;delete t.value,this._super(t),this.options.value=this._constrainedValue(e),this._refreshValue()},_setOption:function(t,e){\"max\"===t&&(e=Math.max(this.min,e)),this._super(t,e)},_percentage:function(){return this.indeterminate?100:100*(this.options.value-this.min)/(this.options.max-this.min)},_refreshValue:function(){var e=this.options.value,i=this._percentage();this.valueDiv.toggle(this.indeterminate||e>this.min).toggleClass(\"ui-corner-right\",e===this.options.max).width(i.toFixed(0)+\"%\"),this.element.toggleClass(\"ui-progressbar-indeterminate\",this.indeterminate),this.indeterminate?(this.element.removeAttr(\"aria-valuenow\"),this.overlayDiv||(this.overlayDiv=t(\"<div class='ui-progressbar-overlay'></div>\").appendTo(this.valueDiv))):(this.element.attr({\"aria-valuemax\":this.options.max,\"aria-valuenow\":e}),this.overlayDiv&&(this.overlayDiv.remove(),this.overlayDiv=null)),this.oldValue!==e&&(this.oldValue=e,this._trigger(\"change\")),e===this.options.max&&this._trigger(\"complete\")}})}(jQuery),function(t){var e=5;t.widget(\"ui.slider\",t.ui.mouse,{version:\"1.10.4\",widgetEventPrefix:\"slide\",options:{animate:!1,distance:0,max:100,min:0,orientation:\"horizontal\",range:!1,step:1,value:0,values:null,change:null,slide:null,start:null,stop:null},_create:function(){this._keySliding=!1,this._mouseSliding=!1,this._animateOff=!0,this._handleIndex=null,this._detectOrientation(),this._mouseInit(),this.element.addClass(\"ui-slider ui-slider-\"+this.orientation+\" ui-widget\"+\" ui-widget-content\"+\" ui-corner-all\"),this._refresh(),this._setOption(\"disabled\",this.options.disabled),this._animateOff=!1},_refresh:function(){this._createRange(),this._createHandles(),this._setupEvents(),this._refreshValue()},_createHandles:function(){var e,i,s=this.options,n=this.element.find(\".ui-slider-handle\").addClass(\"ui-state-default ui-corner-all\"),o=\"<a class='ui-slider-handle ui-state-default ui-corner-all' href='#'></a>\",a=[];for(i=s.values&&s.values.length||1,n.length>i&&(n.slice(i).remove(),n=n.slice(0,i)),e=n.length;i>e;e++)a.push(o);this.handles=n.add(t(a.join(\"\")).appendTo(this.element)),this.handle=this.handles.eq(0),this.handles.each(function(e){t(this).data(\"ui-slider-handle-index\",e)})},_createRange:function(){var e=this.options,i=\"\";e.range?(e.range===!0&&(e.values?e.values.length&&2!==e.values.length?e.values=[e.values[0],e.values[0]]:t.isArray(e.values)&&(e.values=e.values.slice(0)):e.values=[this._valueMin(),this._valueMin()]),this.range&&this.range.length?this.range.removeClass(\"ui-slider-range-min ui-slider-range-max\").css({left:\"\",bottom:\"\"}):(this.range=t(\"<div></div>\").appendTo(this.element),i=\"ui-slider-range ui-widget-header ui-corner-all\"),this.range.addClass(i+(\"min\"===e.range||\"max\"===e.range?\" ui-slider-range-\"+e.range:\"\"))):(this.range&&this.range.remove(),this.range=null)},_setupEvents:function(){var t=this.handles.add(this.range).filter(\"a\");this._off(t),this._on(t,this._handleEvents),this._hoverable(t),this._focusable(t)},_destroy:function(){this.handles.remove(),this.range&&this.range.remove(),this.element.removeClass(\"ui-slider ui-slider-horizontal ui-slider-vertical ui-widget ui-widget-content ui-corner-all\"),this._mouseDestroy()},_mouseCapture:function(e){var i,s,n,o,a,r,h,l,c=this,u=this.options;return u.disabled?!1:(this.elementSize={width:this.element.outerWidth(),height:this.element.outerHeight()},this.elementOffset=this.element.offset(),i={x:e.pageX,y:e.pageY},s=this._normValueFromMouse(i),n=this._valueMax()-this._valueMin()+1,this.handles.each(function(e){var i=Math.abs(s-c.values(e));(n>i||n===i&&(e===c._lastChangedValue||c.values(e)===u.min))&&(n=i,o=t(this),a=e)}),r=this._start(e,a),r===!1?!1:(this._mouseSliding=!0,this._handleIndex=a,o.addClass(\"ui-state-active\").focus(),h=o.offset(),l=!t(e.target).parents().addBack().is(\".ui-slider-handle\"),this._clickOffset=l?{left:0,top:0}:{left:e.pageX-h.left-o.width()/2,top:e.pageY-h.top-o.height()/2-(parseInt(o.css(\"borderTopWidth\"),10)||0)-(parseInt(o.css(\"borderBottomWidth\"),10)||0)+(parseInt(o.css(\"marginTop\"),10)||0)},this.handles.hasClass(\"ui-state-hover\")||this._slide(e,a,s),this._animateOff=!0,!0))},_mouseStart:function(){return!0},_mouseDrag:function(t){var e={x:t.pageX,y:t.pageY},i=this._normValueFromMouse(e);return this._slide(t,this._handleIndex,i),!1},_mouseStop:function(t){return this.handles.removeClass(\"ui-state-active\"),this._mouseSliding=!1,this._stop(t,this._handleIndex),this._change(t,this._handleIndex),this._handleIndex=null,this._clickOffset=null,this._animateOff=!1,!1},_detectOrientation:function(){this.orientation=\"vertical\"===this.options.orientation?\"vertical\":\"horizontal\"},_normValueFromMouse:function(t){var e,i,s,n,o;return\"horizontal\"===this.orientation?(e=this.elementSize.width,i=t.x-this.elementOffset.left-(this._clickOffset?this._clickOffset.left:0)):(e=this.elementSize.height,i=t.y-this.elementOffset.top-(this._clickOffset?this._clickOffset.top:0)),s=i/e,s>1&&(s=1),0>s&&(s=0),\"vertical\"===this.orientation&&(s=1-s),n=this._valueMax()-this._valueMin(),o=this._valueMin()+s*n,this._trimAlignValue(o)},_start:function(t,e){var i={handle:this.handles[e],value:this.value()};return this.options.values&&this.options.values.length&&(i.value=this.values(e),i.values=this.values()),this._trigger(\"start\",t,i)},_slide:function(t,e,i){var s,n,o;this.options.values&&this.options.values.length?(s=this.values(e?0:1),2===this.options.values.length&&this.options.range===!0&&(0===e&&i>s||1===e&&s>i)&&(i=s),i!==this.values(e)&&(n=this.values(),n[e]=i,o=this._trigger(\"slide\",t,{handle:this.handles[e],value:i,values:n}),s=this.values(e?0:1),o!==!1&&this.values(e,i))):i!==this.value()&&(o=this._trigger(\"slide\",t,{handle:this.handles[e],value:i}),o!==!1&&this.value(i))},_stop:function(t,e){var i={handle:this.handles[e],value:this.value()};this.options.values&&this.options.values.length&&(i.value=this.values(e),i.values=this.values()),this._trigger(\"stop\",t,i)},_change:function(t,e){if(!this._keySliding&&!this._mouseSliding){var i={handle:this.handles[e],value:this.value()};this.options.values&&this.options.values.length&&(i.value=this.values(e),i.values=this.values()),this._lastChangedValue=e,this._trigger(\"change\",t,i)}},value:function(t){return arguments.length?(this.options.value=this._trimAlignValue(t),this._refreshValue(),this._change(null,0),undefined):this._value()},values:function(e,i){var s,n,o;if(arguments.length>1)return this.options.values[e]=this._trimAlignValue(i),this._refreshValue(),this._change(null,e),undefined;if(!arguments.length)return this._values();if(!t.isArray(arguments[0]))return this.options.values&&this.options.values.length?this._values(e):this.value();for(s=this.options.values,n=arguments[0],o=0;s.length>o;o+=1)s[o]=this._trimAlignValue(n[o]),this._change(null,o);this._refreshValue()},_setOption:function(e,i){var s,n=0;switch(\"range\"===e&&this.options.range===!0&&(\"min\"===i?(this.options.value=this._values(0),this.options.values=null):\"max\"===i&&(this.options.value=this._values(this.options.values.length-1),this.options.values=null)),t.isArray(this.options.values)&&(n=this.options.values.length),t.Widget.prototype._setOption.apply(this,arguments),e){case\"orientation\":this._detectOrientation(),this.element.removeClass(\"ui-slider-horizontal ui-slider-vertical\").addClass(\"ui-slider-\"+this.orientation),this._refreshValue();break;case\"value\":this._animateOff=!0,this._refreshValue(),this._change(null,0),this._animateOff=!1;break;case\"values\":for(this._animateOff=!0,this._refreshValue(),s=0;n>s;s+=1)this._change(null,s);this._animateOff=!1;break;case\"min\":case\"max\":this._animateOff=!0,this._refreshValue(),this._animateOff=!1;break;case\"range\":this._animateOff=!0,this._refresh(),this._animateOff=!1}},_value:function(){var t=this.options.value;return t=this._trimAlignValue(t)},_values:function(t){var e,i,s;if(arguments.length)return e=this.options.values[t],e=this._trimAlignValue(e);if(this.options.values&&this.options.values.length){for(i=this.options.values.slice(),s=0;i.length>s;s+=1)i[s]=this._trimAlignValue(i[s]);return i}return[]},_trimAlignValue:function(t){if(this._valueMin()>=t)return this._valueMin();if(t>=this._valueMax())return this._valueMax();var e=this.options.step>0?this.options.step:1,i=(t-this._valueMin())%e,s=t-i;return 2*Math.abs(i)>=e&&(s+=i>0?e:-e),parseFloat(s.toFixed(5))},_valueMin:function(){return this.options.min},_valueMax:function(){return this.options.max},_refreshValue:function(){var e,i,s,n,o,a=this.options.range,r=this.options,h=this,l=this._animateOff?!1:r.animate,c={};this.options.values&&this.options.values.length?this.handles.each(function(s){i=100*((h.values(s)-h._valueMin())/(h._valueMax()-h._valueMin())),c[\"horizontal\"===h.orientation?\"left\":\"bottom\"]=i+\"%\",t(this).stop(1,1)[l?\"animate\":\"css\"](c,r.animate),h.options.range===!0&&(\"horizontal\"===h.orientation?(0===s&&h.range.stop(1,1)[l?\"animate\":\"css\"]({left:i+\"%\"},r.animate),1===s&&h.range[l?\"animate\":\"css\"]({width:i-e+\"%\"},{queue:!1,duration:r.animate})):(0===s&&h.range.stop(1,1)[l?\"animate\":\"css\"]({bottom:i+\"%\"},r.animate),1===s&&h.range[l?\"animate\":\"css\"]({height:i-e+\"%\"},{queue:!1,duration:r.animate}))),e=i}):(s=this.value(),n=this._valueMin(),o=this._valueMax(),i=o!==n?100*((s-n)/(o-n)):0,c[\"horizontal\"===this.orientation?\"left\":\"bottom\"]=i+\"%\",this.handle.stop(1,1)[l?\"animate\":\"css\"](c,r.animate),\"min\"===a&&\"horizontal\"===this.orientation&&this.range.stop(1,1)[l?\"animate\":\"css\"]({width:i+\"%\"},r.animate),\"max\"===a&&\"horizontal\"===this.orientation&&this.range[l?\"animate\":\"css\"]({width:100-i+\"%\"},{queue:!1,duration:r.animate}),\"min\"===a&&\"vertical\"===this.orientation&&this.range.stop(1,1)[l?\"animate\":\"css\"]({height:i+\"%\"},r.animate),\"max\"===a&&\"vertical\"===this.orientation&&this.range[l?\"animate\":\"css\"]({height:100-i+\"%\"},{queue:!1,duration:r.animate}))},_handleEvents:{keydown:function(i){var s,n,o,a,r=t(i.target).data(\"ui-slider-handle-index\");switch(i.keyCode){case t.ui.keyCode.HOME:case t.ui.keyCode.END:case t.ui.keyCode.PAGE_UP:case t.ui.keyCode.PAGE_DOWN:case t.ui.keyCode.UP:case t.ui.keyCode.RIGHT:case t.ui.keyCode.DOWN:case t.ui.keyCode.LEFT:if(i.preventDefault(),!this._keySliding&&(this._keySliding=!0,t(i.target).addClass(\"ui-state-active\"),s=this._start(i,r),s===!1))return}switch(a=this.options.step,n=o=this.options.values&&this.options.values.length?this.values(r):this.value(),i.keyCode){case t.ui.keyCode.HOME:o=this._valueMin();break;case t.ui.keyCode.END:o=this._valueMax();break;case t.ui.keyCode.PAGE_UP:o=this._trimAlignValue(n+(this._valueMax()-this._valueMin())/e);break;case t.ui.keyCode.PAGE_DOWN:o=this._trimAlignValue(n-(this._valueMax()-this._valueMin())/e);break;case t.ui.keyCode.UP:case t.ui.keyCode.RIGHT:if(n===this._valueMax())return;o=this._trimAlignValue(n+a);break;case t.ui.keyCode.DOWN:case t.ui.keyCode.LEFT:if(n===this._valueMin())return;o=this._trimAlignValue(n-a)}this._slide(i,r,o)},click:function(t){t.preventDefault()},keyup:function(e){var i=t(e.target).data(\"ui-slider-handle-index\");this._keySliding&&(this._keySliding=!1,this._stop(e,i),this._change(e,i),t(e.target).removeClass(\"ui-state-active\"))}}})}(jQuery),function(t){function e(t){return function(){var e=this.element.val();t.apply(this,arguments),this._refresh(),e!==this.element.val()&&this._trigger(\"change\")}}t.widget(\"ui.spinner\",{version:\"1.10.4\",defaultElement:\"<input>\",widgetEventPrefix:\"spin\",options:{culture:null,icons:{down:\"ui-icon-triangle-1-s\",up:\"ui-icon-triangle-1-n\"},incremental:!0,max:null,min:null,numberFormat:null,page:10,step:1,change:null,spin:null,start:null,stop:null},_create:function(){this._setOption(\"max\",this.options.max),this._setOption(\"min\",this.options.min),this._setOption(\"step\",this.options.step),\"\"!==this.value()&&this._value(this.element.val(),!0),this._draw(),this._on(this._events),this._refresh(),this._on(this.window,{beforeunload:function(){this.element.removeAttr(\"autocomplete\")}})},_getCreateOptions:function(){var e={},i=this.element;return t.each([\"min\",\"max\",\"step\"],function(t,s){var n=i.attr(s);void 0!==n&&n.length&&(e[s]=n)}),e},_events:{keydown:function(t){this._start(t)&&this._keydown(t)&&t.preventDefault()},keyup:\"_stop\",focus:function(){this.previous=this.element.val()},blur:function(t){return this.cancelBlur?(delete this.cancelBlur,void 0):(this._stop(),this._refresh(),this.previous!==this.element.val()&&this._trigger(\"change\",t),void 0)},mousewheel:function(t,e){if(e){if(!this.spinning&&!this._start(t))return!1;this._spin((e>0?1:-1)*this.options.step,t),clearTimeout(this.mousewheelTimer),this.mousewheelTimer=this._delay(function(){this.spinning&&this._stop(t)},100),t.preventDefault()}},\"mousedown .ui-spinner-button\":function(e){function i(){var t=this.element[0]===this.document[0].activeElement;t||(this.element.focus(),this.previous=s,this._delay(function(){this.previous=s}))}var s;s=this.element[0]===this.document[0].activeElement?this.previous:this.element.val(),e.preventDefault(),i.call(this),this.cancelBlur=!0,this._delay(function(){delete this.cancelBlur,i.call(this)}),this._start(e)!==!1&&this._repeat(null,t(e.currentTarget).hasClass(\"ui-spinner-up\")?1:-1,e)},\"mouseup .ui-spinner-button\":\"_stop\",\"mouseenter .ui-spinner-button\":function(e){return t(e.currentTarget).hasClass(\"ui-state-active\")?this._start(e)===!1?!1:(this._repeat(null,t(e.currentTarget).hasClass(\"ui-spinner-up\")?1:-1,e),void 0):void 0},\"mouseleave .ui-spinner-button\":\"_stop\"},_draw:function(){var t=this.uiSpinner=this.element.addClass(\"ui-spinner-input\").attr(\"autocomplete\",\"off\").wrap(this._uiSpinnerHtml()).parent().append(this._buttonHtml());this.element.attr(\"role\",\"spinbutton\"),this.buttons=t.find(\".ui-spinner-button\").attr(\"tabIndex\",-1).button().removeClass(\"ui-corner-all\"),this.buttons.height()>Math.ceil(.5*t.height())&&t.height()>0&&t.height(t.height()),this.options.disabled&&this.disable()},_keydown:function(e){var i=this.options,s=t.ui.keyCode;switch(e.keyCode){case s.UP:return this._repeat(null,1,e),!0;case s.DOWN:return this._repeat(null,-1,e),!0;case s.PAGE_UP:return this._repeat(null,i.page,e),!0;case s.PAGE_DOWN:return this._repeat(null,-i.page,e),!0}return!1},_uiSpinnerHtml:function(){return\"<span class='ui-spinner ui-widget ui-widget-content ui-corner-all'></span>\"},_buttonHtml:function(){return\"<a class='ui-spinner-button ui-spinner-up ui-corner-tr'><span class='ui-icon \"+this.options.icons.up+\"'>&#9650;</span>\"+\"</a>\"+\"<a class='ui-spinner-button ui-spinner-down ui-corner-br'>\"+\"<span class='ui-icon \"+this.options.icons.down+\"'>&#9660;</span>\"+\"</a>\"},_start:function(t){return this.spinning||this._trigger(\"start\",t)!==!1?(this.counter||(this.counter=1),this.spinning=!0,!0):!1},_repeat:function(t,e,i){t=t||500,clearTimeout(this.timer),this.timer=this._delay(function(){this._repeat(40,e,i)},t),this._spin(e*this.options.step,i)},_spin:function(t,e){var i=this.value()||0;this.counter||(this.counter=1),i=this._adjustValue(i+t*this._increment(this.counter)),this.spinning&&this._trigger(\"spin\",e,{value:i})===!1||(this._value(i),this.counter++)},_increment:function(e){var i=this.options.incremental;return i?t.isFunction(i)?i(e):Math.floor(e*e*e/5e4-e*e/500+17*e/200+1):1},_precision:function(){var t=this._precisionOf(this.options.step);return null!==this.options.min&&(t=Math.max(t,this._precisionOf(this.options.min))),t},_precisionOf:function(t){var e=\"\"+t,i=e.indexOf(\".\");return-1===i?0:e.length-i-1},_adjustValue:function(t){var e,i,s=this.options;return e=null!==s.min?s.min:0,i=t-e,i=Math.round(i/s.step)*s.step,t=e+i,t=parseFloat(t.toFixed(this._precision())),null!==s.max&&t>s.max?s.max:null!==s.min&&s.min>t?s.min:t},_stop:function(t){this.spinning&&(clearTimeout(this.timer),clearTimeout(this.mousewheelTimer),this.counter=0,this.spinning=!1,this._trigger(\"stop\",t))},_setOption:function(t,e){if(\"culture\"===t||\"numberFormat\"===t){var i=this._parse(this.element.val());return this.options[t]=e,this.element.val(this._format(i)),void 0}(\"max\"===t||\"min\"===t||\"step\"===t)&&\"string\"==typeof e&&(e=this._parse(e)),\"icons\"===t&&(this.buttons.first().find(\".ui-icon\").removeClass(this.options.icons.up).addClass(e.up),this.buttons.last().find(\".ui-icon\").removeClass(this.options.icons.down).addClass(e.down)),this._super(t,e),\"disabled\"===t&&(e?(this.element.prop(\"disabled\",!0),this.buttons.button(\"disable\")):(this.element.prop(\"disabled\",!1),this.buttons.button(\"enable\")))},_setOptions:e(function(t){this._super(t),this._value(this.element.val())}),_parse:function(t){return\"string\"==typeof t&&\"\"!==t&&(t=window.Globalize&&this.options.numberFormat?Globalize.parseFloat(t,10,this.options.culture):+t),\"\"===t||isNaN(t)?null:t},_format:function(t){return\"\"===t?\"\":window.Globalize&&this.options.numberFormat?Globalize.format(t,this.options.numberFormat,this.options.culture):t},_refresh:function(){this.element.attr({\"aria-valuemin\":this.options.min,\"aria-valuemax\":this.options.max,\"aria-valuenow\":this._parse(this.element.val())})},_value:function(t,e){var i;\"\"!==t&&(i=this._parse(t),null!==i&&(e||(i=this._adjustValue(i)),t=this._format(i))),this.element.val(t),this._refresh()},_destroy:function(){this.element.removeClass(\"ui-spinner-input\").prop(\"disabled\",!1).removeAttr(\"autocomplete\").removeAttr(\"role\").removeAttr(\"aria-valuemin\").removeAttr(\"aria-valuemax\").removeAttr(\"aria-valuenow\"),this.uiSpinner.replaceWith(this.element)},stepUp:e(function(t){this._stepUp(t)}),_stepUp:function(t){this._start()&&(this._spin((t||1)*this.options.step),this._stop())},stepDown:e(function(t){this._stepDown(t)}),_stepDown:function(t){this._start()&&(this._spin((t||1)*-this.options.step),this._stop())},pageUp:e(function(t){this._stepUp((t||1)*this.options.page)}),pageDown:e(function(t){this._stepDown((t||1)*this.options.page)}),value:function(t){return arguments.length?(e(this._value).call(this,t),void 0):this._parse(this.element.val())},widget:function(){return this.uiSpinner}})}(jQuery),function(t,e){function i(){return++n}function s(t){return t=t.cloneNode(!1),t.hash.length>1&&decodeURIComponent(t.href.replace(o,\"\"))===decodeURIComponent(location.href.replace(o,\"\"))}var n=0,o=/#.*$/;t.widget(\"ui.tabs\",{version:\"1.10.4\",delay:300,options:{active:null,collapsible:!1,event:\"click\",heightStyle:\"content\",hide:null,show:null,activate:null,beforeActivate:null,beforeLoad:null,load:null},_create:function(){var e=this,i=this.options;this.running=!1,this.element.addClass(\"ui-tabs ui-widget ui-widget-content ui-corner-all\").toggleClass(\"ui-tabs-collapsible\",i.collapsible).delegate(\".ui-tabs-nav > li\",\"mousedown\"+this.eventNamespace,function(e){t(this).is(\".ui-state-disabled\")&&e.preventDefault()}).delegate(\".ui-tabs-anchor\",\"focus\"+this.eventNamespace,function(){t(this).closest(\"li\").is(\".ui-state-disabled\")&&this.blur()}),this._processTabs(),i.active=this._initialActive(),t.isArray(i.disabled)&&(i.disabled=t.unique(i.disabled.concat(t.map(this.tabs.filter(\".ui-state-disabled\"),function(t){return e.tabs.index(t)}))).sort()),this.active=this.options.active!==!1&&this.anchors.length?this._findActive(i.active):t(),this._refresh(),this.active.length&&this.load(i.active)},_initialActive:function(){var i=this.options.active,s=this.options.collapsible,n=location.hash.substring(1);return null===i&&(n&&this.tabs.each(function(s,o){return t(o).attr(\"aria-controls\")===n?(i=s,!1):e}),null===i&&(i=this.tabs.index(this.tabs.filter(\".ui-tabs-active\"))),(null===i||-1===i)&&(i=this.tabs.length?0:!1)),i!==!1&&(i=this.tabs.index(this.tabs.eq(i)),-1===i&&(i=s?!1:0)),!s&&i===!1&&this.anchors.length&&(i=0),i},_getCreateEventData:function(){return{tab:this.active,panel:this.active.length?this._getPanelForTab(this.active):t()}},_tabKeydown:function(i){var s=t(this.document[0].activeElement).closest(\"li\"),n=this.tabs.index(s),o=!0;if(!this._handlePageNav(i)){switch(i.keyCode){case t.ui.keyCode.RIGHT:case t.ui.keyCode.DOWN:n++;break;case t.ui.keyCode.UP:case t.ui.keyCode.LEFT:o=!1,n--;break;case t.ui.keyCode.END:n=this.anchors.length-1;break;case t.ui.keyCode.HOME:n=0;break;case t.ui.keyCode.SPACE:return i.preventDefault(),clearTimeout(this.activating),this._activate(n),e;case t.ui.keyCode.ENTER:return i.preventDefault(),clearTimeout(this.activating),this._activate(n===this.options.active?!1:n),e;default:return}i.preventDefault(),clearTimeout(this.activating),n=this._focusNextTab(n,o),i.ctrlKey||(s.attr(\"aria-selected\",\"false\"),this.tabs.eq(n).attr(\"aria-selected\",\"true\"),this.activating=this._delay(function(){this.option(\"active\",n)},this.delay))}},_panelKeydown:function(e){this._handlePageNav(e)||e.ctrlKey&&e.keyCode===t.ui.keyCode.UP&&(e.preventDefault(),this.active.focus())},_handlePageNav:function(i){return i.altKey&&i.keyCode===t.ui.keyCode.PAGE_UP?(this._activate(this._focusNextTab(this.options.active-1,!1)),!0):i.altKey&&i.keyCode===t.ui.keyCode.PAGE_DOWN?(this._activate(this._focusNextTab(this.options.active+1,!0)),!0):e},_findNextTab:function(e,i){function s(){return e>n&&(e=0),0>e&&(e=n),e}for(var n=this.tabs.length-1;-1!==t.inArray(s(),this.options.disabled);)e=i?e+1:e-1;return e},_focusNextTab:function(t,e){return t=this._findNextTab(t,e),this.tabs.eq(t).focus(),t},_setOption:function(t,i){return\"active\"===t?(this._activate(i),e):\"disabled\"===t?(this._setupDisabled(i),e):(this._super(t,i),\"collapsible\"===t&&(this.element.toggleClass(\"ui-tabs-collapsible\",i),i||this.options.active!==!1||this._activate(0)),\"event\"===t&&this._setupEvents(i),\"heightStyle\"===t&&this._setupHeightStyle(i),e)},_tabId:function(t){return t.attr(\"aria-controls\")||\"ui-tabs-\"+i()},_sanitizeSelector:function(t){return t?t.replace(/[!\"$%&'()*+,.\\/:;<=>?@\\[\\]\\^`{|}~]/g,\"\\\\$&\"):\"\"},refresh:function(){var e=this.options,i=this.tablist.children(\":has(a[href])\");e.disabled=t.map(i.filter(\".ui-state-disabled\"),function(t){return i.index(t)}),this._processTabs(),e.active!==!1&&this.anchors.length?this.active.length&&!t.contains(this.tablist[0],this.active[0])?this.tabs.length===e.disabled.length?(e.active=!1,this.active=t()):this._activate(this._findNextTab(Math.max(0,e.active-1),!1)):e.active=this.tabs.index(this.active):(e.active=!1,this.active=t()),this._refresh()},_refresh:function(){this._setupDisabled(this.options.disabled),this._setupEvents(this.options.event),this._setupHeightStyle(this.options.heightStyle),this.tabs.not(this.active).attr({\"aria-selected\":\"false\",tabIndex:-1}),this.panels.not(this._getPanelForTab(this.active)).hide().attr({\"aria-expanded\":\"false\",\"aria-hidden\":\"true\"}),this.active.length?(this.active.addClass(\"ui-tabs-active ui-state-active\").attr({\"aria-selected\":\"true\",tabIndex:0}),this._getPanelForTab(this.active).show().attr({\"aria-expanded\":\"true\",\"aria-hidden\":\"false\"})):this.tabs.eq(0).attr(\"tabIndex\",0)},_processTabs:function(){var e=this;this.tablist=this._getList().addClass(\"ui-tabs-nav ui-helper-reset ui-helper-clearfix ui-widget-header ui-corner-all\").attr(\"role\",\"tablist\"),this.tabs=this.tablist.find(\"> li:has(a[href])\").addClass(\"ui-state-default ui-corner-top\").attr({role:\"tab\",tabIndex:-1}),this.anchors=this.tabs.map(function(){return t(\"a\",this)[0]}).addClass(\"ui-tabs-anchor\").attr({role:\"presentation\",tabIndex:-1}),this.panels=t(),this.anchors.each(function(i,n){var o,a,r,h=t(n).uniqueId().attr(\"id\"),l=t(n).closest(\"li\"),c=l.attr(\"aria-controls\");s(n)?(o=n.hash,a=e.element.find(e._sanitizeSelector(o))):(r=e._tabId(l),o=\"#\"+r,a=e.element.find(o),a.length||(a=e._createPanel(r),a.insertAfter(e.panels[i-1]||e.tablist)),a.attr(\"aria-live\",\"polite\")),a.length&&(e.panels=e.panels.add(a)),c&&l.data(\"ui-tabs-aria-controls\",c),l.attr({\"aria-controls\":o.substring(1),\"aria-labelledby\":h}),a.attr(\"aria-labelledby\",h)}),this.panels.addClass(\"ui-tabs-panel ui-widget-content ui-corner-bottom\").attr(\"role\",\"tabpanel\")},_getList:function(){return this.tablist||this.element.find(\"ol,ul\").eq(0)},_createPanel:function(e){return t(\"<div>\").attr(\"id\",e).addClass(\"ui-tabs-panel ui-widget-content ui-corner-bottom\").data(\"ui-tabs-destroy\",!0)},_setupDisabled:function(e){t.isArray(e)&&(e.length?e.length===this.anchors.length&&(e=!0):e=!1);for(var i,s=0;i=this.tabs[s];s++)e===!0||-1!==t.inArray(s,e)?t(i).addClass(\"ui-state-disabled\").attr(\"aria-disabled\",\"true\"):t(i).removeClass(\"ui-state-disabled\").removeAttr(\"aria-disabled\");this.options.disabled=e},_setupEvents:function(e){var i={click:function(t){t.preventDefault()}};e&&t.each(e.split(\" \"),function(t,e){i[e]=\"_eventHandler\"}),this._off(this.anchors.add(this.tabs).add(this.panels)),this._on(this.anchors,i),this._on(this.tabs,{keydown:\"_tabKeydown\"}),this._on(this.panels,{keydown:\"_panelKeydown\"}),this._focusable(this.tabs),this._hoverable(this.tabs)},_setupHeightStyle:function(e){var i,s=this.element.parent();\"fill\"===e?(i=s.height(),i-=this.element.outerHeight()-this.element.height(),this.element.siblings(\":visible\").each(function(){var e=t(this),s=e.css(\"position\");\"absolute\"!==s&&\"fixed\"!==s&&(i-=e.outerHeight(!0))}),this.element.children().not(this.panels).each(function(){i-=t(this).outerHeight(!0)}),this.panels.each(function(){t(this).height(Math.max(0,i-t(this).innerHeight()+t(this).height()))}).css(\"overflow\",\"auto\")):\"auto\"===e&&(i=0,this.panels.each(function(){i=Math.max(i,t(this).height(\"\").height())}).height(i))},_eventHandler:function(e){var i=this.options,s=this.active,n=t(e.currentTarget),o=n.closest(\"li\"),a=o[0]===s[0],r=a&&i.collapsible,h=r?t():this._getPanelForTab(o),l=s.length?this._getPanelForTab(s):t(),c={oldTab:s,oldPanel:l,newTab:r?t():o,newPanel:h};e.preventDefault(),o.hasClass(\"ui-state-disabled\")||o.hasClass(\"ui-tabs-loading\")||this.running||a&&!i.collapsible||this._trigger(\"beforeActivate\",e,c)===!1||(i.active=r?!1:this.tabs.index(o),this.active=a?t():o,this.xhr&&this.xhr.abort(),l.length||h.length||t.error(\"jQuery UI Tabs: Mismatching fragment identifier.\"),h.length&&this.load(this.tabs.index(o),e),this._toggle(e,c))},_toggle:function(e,i){function s(){o.running=!1,o._trigger(\"activate\",e,i)}function n(){i.newTab.closest(\"li\").addClass(\"ui-tabs-active ui-state-active\"),a.length&&o.options.show?o._show(a,o.options.show,s):(a.show(),s())}var o=this,a=i.newPanel,r=i.oldPanel;this.running=!0,r.length&&this.options.hide?this._hide(r,this.options.hide,function(){i.oldTab.closest(\"li\").removeClass(\"ui-tabs-active ui-state-active\"),n()}):(i.oldTab.closest(\"li\").removeClass(\"ui-tabs-active ui-state-active\"),r.hide(),n()),r.attr({\"aria-expanded\":\"false\",\"aria-hidden\":\"true\"}),i.oldTab.attr(\"aria-selected\",\"false\"),a.length&&r.length?i.oldTab.attr(\"tabIndex\",-1):a.length&&this.tabs.filter(function(){return 0===t(this).attr(\"tabIndex\")}).attr(\"tabIndex\",-1),a.attr({\"aria-expanded\":\"true\",\"aria-hidden\":\"false\"}),i.newTab.attr({\"aria-selected\":\"true\",tabIndex:0})},_activate:function(e){var i,s=this._findActive(e);s[0]!==this.active[0]&&(s.length||(s=this.active),i=s.find(\".ui-tabs-anchor\")[0],this._eventHandler({target:i,currentTarget:i,preventDefault:t.noop}))},_findActive:function(e){return e===!1?t():this.tabs.eq(e)},_getIndex:function(t){return\"string\"==typeof t&&(t=this.anchors.index(this.anchors.filter(\"[href$='\"+t+\"']\"))),t},_destroy:function(){this.xhr&&this.xhr.abort(),this.element.removeClass(\"ui-tabs ui-widget ui-widget-content ui-corner-all ui-tabs-collapsible\"),this.tablist.removeClass(\"ui-tabs-nav ui-helper-reset ui-helper-clearfix ui-widget-header ui-corner-all\").removeAttr(\"role\"),this.anchors.removeClass(\"ui-tabs-anchor\").removeAttr(\"role\").removeAttr(\"tabIndex\").removeUniqueId(),this.tabs.add(this.panels).each(function(){t.data(this,\"ui-tabs-destroy\")?t(this).remove():t(this).removeClass(\"ui-state-default ui-state-active ui-state-disabled ui-corner-top ui-corner-bottom ui-widget-content ui-tabs-active ui-tabs-panel\").removeAttr(\"tabIndex\").removeAttr(\"aria-live\").removeAttr(\"aria-busy\").removeAttr(\"aria-selected\").removeAttr(\"aria-labelledby\").removeAttr(\"aria-hidden\").removeAttr(\"aria-expanded\").removeAttr(\"role\")}),this.tabs.each(function(){var e=t(this),i=e.data(\"ui-tabs-aria-controls\");i?e.attr(\"aria-controls\",i).removeData(\"ui-tabs-aria-controls\"):e.removeAttr(\"aria-controls\")}),this.panels.show(),\"content\"!==this.options.heightStyle&&this.panels.css(\"height\",\"\")},enable:function(i){var s=this.options.disabled;s!==!1&&(i===e?s=!1:(i=this._getIndex(i),s=t.isArray(s)?t.map(s,function(t){return t!==i?t:null}):t.map(this.tabs,function(t,e){return e!==i?e:null})),this._setupDisabled(s))},disable:function(i){var s=this.options.disabled;if(s!==!0){if(i===e)s=!0;else{if(i=this._getIndex(i),-1!==t.inArray(i,s))return;s=t.isArray(s)?t.merge([i],s).sort():[i]}this._setupDisabled(s)}},load:function(e,i){e=this._getIndex(e);var n=this,o=this.tabs.eq(e),a=o.find(\".ui-tabs-anchor\"),r=this._getPanelForTab(o),h={tab:o,panel:r};s(a[0])||(this.xhr=t.ajax(this._ajaxSettings(a,i,h)),this.xhr&&\"canceled\"!==this.xhr.statusText&&(o.addClass(\"ui-tabs-loading\"),r.attr(\"aria-busy\",\"true\"),this.xhr.success(function(t){setTimeout(function(){r.html(t),n._trigger(\"load\",i,h)},1)}).complete(function(t,e){setTimeout(function(){\"abort\"===e&&n.panels.stop(!1,!0),o.removeClass(\"ui-tabs-loading\"),r.removeAttr(\"aria-busy\"),t===n.xhr&&delete n.xhr},1)})))},_ajaxSettings:function(e,i,s){var n=this;return{url:e.attr(\"href\"),beforeSend:function(e,o){return n._trigger(\"beforeLoad\",i,t.extend({jqXHR:e,ajaxSettings:o},s))}}},_getPanelForTab:function(e){var i=t(e).attr(\"aria-controls\");return this.element.find(this._sanitizeSelector(\"#\"+i))}})}(jQuery),function(t){function e(e,i){var s=(e.attr(\"aria-describedby\")||\"\").split(/\\s+/);s.push(i),e.data(\"ui-tooltip-id\",i).attr(\"aria-describedby\",t.trim(s.join(\" \")))}function i(e){var i=e.data(\"ui-tooltip-id\"),s=(e.attr(\"aria-describedby\")||\"\").split(/\\s+/),n=t.inArray(i,s);-1!==n&&s.splice(n,1),e.removeData(\"ui-tooltip-id\"),s=t.trim(s.join(\" \")),s?e.attr(\"aria-describedby\",s):e.removeAttr(\"aria-describedby\")}var s=0;t.widget(\"ui.tooltip\",{version:\"1.10.4\",options:{content:function(){var e=t(this).attr(\"title\")||\"\";return t(\"<a>\").text(e).html()},hide:!0,items:\"[title]:not([disabled])\",position:{my:\"left top+15\",at:\"left bottom\",collision:\"flipfit flip\"},show:!0,tooltipClass:null,track:!1,close:null,open:null},_create:function(){this._on({mouseover:\"open\",focusin:\"open\"}),this.tooltips={},this.parents={},this.options.disabled&&this._disable()},_setOption:function(e,i){var s=this;return\"disabled\"===e?(this[i?\"_disable\":\"_enable\"](),this.options[e]=i,void 0):(this._super(e,i),\"content\"===e&&t.each(this.tooltips,function(t,e){s._updateContent(e)}),void 0)},_disable:function(){var e=this;t.each(this.tooltips,function(i,s){var n=t.Event(\"blur\");n.target=n.currentTarget=s[0],e.close(n,!0)}),this.element.find(this.options.items).addBack().each(function(){var e=t(this);e.is(\"[title]\")&&e.data(\"ui-tooltip-title\",e.attr(\"title\")).attr(\"title\",\"\")})},_enable:function(){this.element.find(this.options.items).addBack().each(function(){var e=t(this);e.data(\"ui-tooltip-title\")&&e.attr(\"title\",e.data(\"ui-tooltip-title\"))})},open:function(e){var i=this,s=t(e?e.target:this.element).closest(this.options.items);s.length&&!s.data(\"ui-tooltip-id\")&&(s.attr(\"title\")&&s.data(\"ui-tooltip-title\",s.attr(\"title\")),s.data(\"ui-tooltip-open\",!0),e&&\"mouseover\"===e.type&&s.parents().each(function(){var e,s=t(this);s.data(\"ui-tooltip-open\")&&(e=t.Event(\"blur\"),e.target=e.currentTarget=this,i.close(e,!0)),s.attr(\"title\")&&(s.uniqueId(),i.parents[this.id]={element:this,title:s.attr(\"title\")},s.attr(\"title\",\"\"))}),this._updateContent(s,e))},_updateContent:function(t,e){var i,s=this.options.content,n=this,o=e?e.type:null;\n" +
                    "return\"string\"==typeof s?this._open(e,t,s):(i=s.call(t[0],function(i){t.data(\"ui-tooltip-open\")&&n._delay(function(){e&&(e.type=o),this._open(e,t,i)})}),i&&this._open(e,t,i),void 0)},_open:function(i,s,n){function o(t){l.of=t,a.is(\":hidden\")||a.position(l)}var a,r,h,l=t.extend({},this.options.position);if(n){if(a=this._find(s),a.length)return a.find(\".ui-tooltip-content\").html(n),void 0;s.is(\"[title]\")&&(i&&\"mouseover\"===i.type?s.attr(\"title\",\"\"):s.removeAttr(\"title\")),a=this._tooltip(s),e(s,a.attr(\"id\")),a.find(\".ui-tooltip-content\").html(n),this.options.track&&i&&/^mouse/.test(i.type)?(this._on(this.document,{mousemove:o}),o(i)):a.position(t.extend({of:s},this.options.position)),a.hide(),this._show(a,this.options.show),this.options.show&&this.options.show.delay&&(h=this.delayedShow=setInterval(function(){a.is(\":visible\")&&(o(l.of),clearInterval(h))},t.fx.interval)),this._trigger(\"open\",i,{tooltip:a}),r={keyup:function(e){if(e.keyCode===t.ui.keyCode.ESCAPE){var i=t.Event(e);i.currentTarget=s[0],this.close(i,!0)}},remove:function(){this._removeTooltip(a)}},i&&\"mouseover\"!==i.type||(r.mouseleave=\"close\"),i&&\"focusin\"!==i.type||(r.focusout=\"close\"),this._on(!0,s,r)}},close:function(e){var s=this,n=t(e?e.currentTarget:this.element),o=this._find(n);this.closing||(clearInterval(this.delayedShow),n.data(\"ui-tooltip-title\")&&n.attr(\"title\",n.data(\"ui-tooltip-title\")),i(n),o.stop(!0),this._hide(o,this.options.hide,function(){s._removeTooltip(t(this))}),n.removeData(\"ui-tooltip-open\"),this._off(n,\"mouseleave focusout keyup\"),n[0]!==this.element[0]&&this._off(n,\"remove\"),this._off(this.document,\"mousemove\"),e&&\"mouseleave\"===e.type&&t.each(this.parents,function(e,i){t(i.element).attr(\"title\",i.title),delete s.parents[e]}),this.closing=!0,this._trigger(\"close\",e,{tooltip:o}),this.closing=!1)},_tooltip:function(e){var i=\"ui-tooltip-\"+s++,n=t(\"<div>\").attr({id:i,role:\"tooltip\"}).addClass(\"ui-tooltip ui-widget ui-corner-all ui-widget-content \"+(this.options.tooltipClass||\"\"));return t(\"<div>\").addClass(\"ui-tooltip-content\").appendTo(n),n.appendTo(this.document[0].body),this.tooltips[i]=e,n},_find:function(e){var i=e.data(\"ui-tooltip-id\");return i?t(\"#\"+i):t()},_removeTooltip:function(t){t.remove(),delete this.tooltips[t.attr(\"id\")]},_destroy:function(){var e=this;t.each(this.tooltips,function(i,s){var n=t.Event(\"blur\");n.target=n.currentTarget=s[0],e.close(n,!0),t(\"#\"+i).remove(),s.data(\"ui-tooltip-title\")&&(s.attr(\"title\",s.data(\"ui-tooltip-title\")),s.removeData(\"ui-tooltip-title\"))})}})}(jQuery);jQuery(function($){ $.datepicker.regional['zh-CN'] = { closeText: '关闭', prevText: '<上月', nextText: '下月>', currentText: '今天', monthNames: ['一月','二月','三月','四月','五月','六月', '七月','八月','九月','十月','十一月','十二月'], monthNamesShort: ['一','二','三','四','五','六', '七','八','九','十','十一','十二'], dayNames: ['星期日','星期一','星期二','星期三','星期四','星期五','星期六'], dayNamesShort: ['周日','周一','周二','周三','周四','周五','周六'], dayNamesMin: ['日','一','二','三','四','五','六'], weekHeader: '周', dateFormat: 'yy-mm-dd', firstDay: 1, isRTL: false, showMonthAfterYear: true, yearSuffix: '年'}; $.datepicker.setDefaults($.datepicker.regional['zh-CN']);});");
            System.out.println("write to file success : " + file.getPath());
        } catch (IOException e) {
            e.printStackTrace();
        } finally {
            MybatisUtilCommon.closeBufferWriterAndFileOutputStream(fileOutputStream, bufferedWriter);
        }
    }

    public static void writeCommonPageCommonCssJqueryUiCss(String htmlPath, String serverUrl) {
        File file = null;
        OutputStream fileOutputStream = null;
        BufferedWriter bufferedWriter = null;
        try {
            File folder = new File(htmlPath + "/common/page-common/css/");
            folder.mkdirs();
            file = new File(htmlPath + "/common/page-common/css/jquery-ui.css");
            //如果文件不存在，则创建文件，如果已存在，则覆盖
            file.createNewFile();
            fileOutputStream = new FileOutputStream(file);
            bufferedWriter = new BufferedWriter(new OutputStreamWriter(fileOutputStream, "utf-8"));
            bufferedWriter.write(".ui-draggable-handle { -ms-touch-action: none; touch-action: none}.ui-helper-hidden { display: none}.ui-helper-hidden-accessible { border: 0; clip: rect(0 0 0 0); height: 1px; margin: -1px; overflow: hidden; padding: 0; position: absolute; width: 1px}.ui-helper-reset { margin: 0; padding: 0; border: 0; outline: 0; line-height: 1.3; text-decoration: none; font-size: 100%; list-style: none}.ui-helper-clearfix:before, .ui-helper-clearfix:after { content: \"\"; display: table; border-collapse: collapse}.ui-helper-clearfix:after { clear: both}.ui-helper-zfix { width: 100%; height: 100%; top: 0; left: 0; position: absolute; opacity: 0; filter: Alpha(Opacity=0)}.ui-front { z-index: 100}.ui-state-disabled { cursor: default !important; pointer-events: none}.ui-icon { display: inline-block; vertical-align: middle; margin-top: -.25em; position: relative; text-indent: -99999px; overflow: hidden; background-repeat: no-repeat}.ui-widget-icon-block { left: 50%; margin-left: -8px; display: block}.ui-widget-overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%}.ui-resizable { position: relative}.ui-resizable-handle { position: absolute; font-size: 0.1px; display: block; -ms-touch-action: none; touch-action: none}.ui-resizable-disabled .ui-resizable-handle, .ui-resizable-autohide .ui-resizable-handle { display: none}.ui-resizable-n { cursor: n-resize; height: 7px; width: 100%; top: -5px; left: 0}.ui-resizable-s { cursor: s-resize; height: 7px; width: 100%; bottom: -5px; left: 0}.ui-resizable-e { cursor: e-resize; width: 7px; right: -5px; top: 0; height: 100%}.ui-resizable-w { cursor: w-resize; width: 7px; left: -5px; top: 0; height: 100%}.ui-resizable-se { cursor: se-resize; width: 12px; height: 12px; right: 1px; bottom: 1px}.ui-resizable-sw { cursor: sw-resize; width: 9px; height: 9px; left: -5px; bottom: -5px}.ui-resizable-nw { cursor: nw-resize; width: 9px; height: 9px; left: -5px; top: -5px}.ui-resizable-ne { cursor: ne-resize; width: 9px; height: 9px; right: -5px; top: -5px}.ui-selectable { -ms-touch-action: none; touch-action: none}.ui-selectable-helper { position: absolute; z-index: 100; border: 1px dotted black}.ui-sortable-handle { -ms-touch-action: none; touch-action: none}.ui-accordion .ui-accordion-header { display: block; cursor: pointer; position: relative; margin: 2px 0 0 0; padding: .5em .5em .5em .7em; font-size: 100%}.ui-accordion .ui-accordion-content { padding: 1em 2.2em; border-top: 0; overflow: auto}.ui-autocomplete { position: absolute; top: 0; left: 0; cursor: default}.ui-menu { list-style: none; padding: 0; margin: 0; display: block; outline: 0}.ui-menu .ui-menu { position: absolute}.ui-menu .ui-menu-item { margin: 0; cursor: pointer; list-style-image: url(\"\")}.ui-menu .ui-menu-item-wrapper { position: relative; padding: 3px 1em 3px .4em}.ui-menu .ui-menu-divider { margin: 5px 0; height: 0; font-size: 0; line-height: 0; border-width: 1px 0 0 0}.ui-menu .ui-state-focus, .ui-menu .ui-state-active { margin: -1px}.ui-menu-icons { position: relative}.ui-menu-icons .ui-menu-item-wrapper { padding-left: 2em}.ui-menu .ui-icon { position: absolute; top: 0; bottom: 0; left: .2em; margin: auto 0}.ui-menu .ui-menu-icon { left: auto; right: 0}.ui-button { padding: .4em 1em; display: inline-block; position: relative; line-height: normal; margin-right: .1em; cursor: pointer; vertical-align: middle; text-align: center; -webkit-user-select: none; -moz-user-select: none; -ms-user-select: none; user-select: none; overflow: visible}.ui-button, .ui-button:link, .ui-button:visited, .ui-button:hover, .ui-button:active { text-decoration: none}.ui-button-icon-only { width: 2em; box-sizing: border-box; text-indent: -9999px; white-space: nowrap}input.ui-button.ui-button-icon-only { text-indent: 0}.ui-button-icon-only .ui-icon { position: absolute; top: 50%; left: 50%; margin-top: -8px; margin-left: -8px}.ui-button.ui-icon-notext .ui-icon { padding: 0; width: 2.1em; height: 2.1em; text-indent: -9999px; white-space: nowrap}input.ui-button.ui-icon-notext .ui-icon { width: auto; height: auto; text-indent: 0; white-space: normal; padding: .4em 1em}input.ui-button::-moz-focus-inner, button.ui-button::-moz-focus-inner { border: 0; padding: 0}.ui-controlgroup { vertical-align: middle; display: inline-block}.ui-controlgroup > .ui-controlgroup-item { float: left; margin-left: 0; margin-right: 0}.ui-controlgroup > .ui-controlgroup-item:focus, .ui-controlgroup > .ui-controlgroup-item.ui-visual-focus { z-index: 9999}.ui-controlgroup-vertical > .ui-controlgroup-item { display: block; float: none; width: 100%; margin-top: 0; margin-bottom: 0; text-align: left}.ui-controlgroup-vertical .ui-controlgroup-item { box-sizing: border-box}.ui-controlgroup .ui-controlgroup-label { padding: .4em 1em}.ui-controlgroup .ui-controlgroup-label span { font-size: 80%}.ui-controlgroup-horizontal .ui-controlgroup-label + .ui-controlgroup-item { border-left: none}.ui-controlgroup-vertical .ui-controlgroup-label + .ui-controlgroup-item { border-top: none}.ui-controlgroup-horizontal .ui-controlgroup-label.ui-widget-content { border-right: none}.ui-controlgroup-vertical .ui-controlgroup-label.ui-widget-content { border-bottom: none}.ui-controlgroup-vertical .ui-spinner-input { width: 75%; width: calc(100% - 2.4em)}.ui-controlgroup-vertical .ui-spinner .ui-spinner-up { border-top-style: solid}.ui-checkboxradio-label .ui-icon-background { box-shadow: inset 1px 1px 1px #ccc; border-radius: .12em; border: none}.ui-checkboxradio-radio-label .ui-icon-background { width: 16px; height: 16px; border-radius: 1em; overflow: visible; border: none}.ui-checkboxradio-radio-label.ui-checkboxradio-checked .ui-icon, .ui-checkboxradio-radio-label.ui-checkboxradio-checked:hover .ui-icon { background-image: none; width: 8px; height: 8px; border-width: 4px; border-style: solid}.ui-checkboxradio-disabled { pointer-events: none}.ui-datepicker { width: 17em; padding: .2em .2em 0; display: none}.ui-datepicker .ui-datepicker-header { position: relative; padding: .2em 0}.ui-datepicker .ui-datepicker-prev, .ui-datepicker .ui-datepicker-next { position: absolute; top: 2px; width: 1.8em; height: 1.8em}.ui-datepicker .ui-datepicker-prev-hover, .ui-datepicker .ui-datepicker-next-hover { top: 1px}.ui-datepicker .ui-datepicker-prev { left: 2px}.ui-datepicker .ui-datepicker-next { right: 2px}.ui-datepicker .ui-datepicker-prev-hover { left: 1px}.ui-datepicker .ui-datepicker-next-hover { right: 1px}.ui-datepicker .ui-datepicker-prev span, .ui-datepicker .ui-datepicker-next span { display: block; position: absolute; left: 50%; margin-left: -8px; top: 50%; margin-top: -8px}.ui-datepicker .ui-datepicker-title { margin: 0 2.3em; line-height: 1.8em; text-align: center}.ui-datepicker .ui-datepicker-title select { font-size: 1em; margin: 1px 0}.ui-datepicker select.ui-datepicker-month, .ui-datepicker select.ui-datepicker-year { width: 45%}.ui-datepicker table { width: 100%; font-size: .9em; border-collapse: collapse; margin: 0 0 .4em}.ui-datepicker th { padding: .7em .3em; text-align: center; font-weight: bold; border: 0}.ui-datepicker td { border: 0; padding: 1px}.ui-datepicker td span, .ui-datepicker td a { display: block; padding: .2em; text-align: right; text-decoration: none}.ui-datepicker .ui-datepicker-buttonpane { background-image: none; margin: .7em 0 0 0; padding: 0 .2em; border-left: 0; border-right: 0; border-bottom: 0}.ui-datepicker .ui-datepicker-buttonpane button { float: right; margin: .5em .2em .4em; cursor: pointer; padding: .2em .6em .3em .6em; width: auto; overflow: visible}.ui-datepicker .ui-datepicker-buttonpane button.ui-datepicker-current { float: left}.ui-datepicker.ui-datepicker-multi { width: auto}.ui-datepicker-multi .ui-datepicker-group { float: left}.ui-datepicker-multi .ui-datepicker-group table { width: 95%; margin: 0 auto .4em}.ui-datepicker-multi-2 .ui-datepicker-group { width: 50%}.ui-datepicker-multi-3 .ui-datepicker-group { width: 33.3%}.ui-datepicker-multi-4 .ui-datepicker-group { width: 25%}.ui-datepicker-multi .ui-datepicker-group-last .ui-datepicker-header, .ui-datepicker-multi .ui-datepicker-group-middle .ui-datepicker-header { border-left-width: 0}.ui-datepicker-multi .ui-datepicker-buttonpane { clear: left}.ui-datepicker-row-break { clear: both; width: 100%; font-size: 0}.ui-datepicker-rtl { direction: rtl}.ui-datepicker-rtl .ui-datepicker-prev { right: 2px; left: auto}.ui-datepicker-rtl .ui-datepicker-next { left: 2px; right: auto}.ui-datepicker-rtl .ui-datepicker-prev:hover { right: 1px; left: auto}.ui-datepicker-rtl .ui-datepicker-next:hover { left: 1px; right: auto}.ui-datepicker-rtl .ui-datepicker-buttonpane { clear: right}.ui-datepicker-rtl .ui-datepicker-buttonpane button { float: left}.ui-datepicker-rtl .ui-datepicker-buttonpane button.ui-datepicker-current, .ui-datepicker-rtl .ui-datepicker-group { float: right}.ui-datepicker-rtl .ui-datepicker-group-last .ui-datepicker-header, .ui-datepicker-rtl .ui-datepicker-group-middle .ui-datepicker-header { border-right-width: 0; border-left-width: 1px}.ui-datepicker .ui-icon { display: block; text-indent: -99999px; overflow: hidden; background-repeat: no-repeat; left: .5em; top: .3em}.ui-dialog { position: absolute; top: 0; left: 0; padding: .2em; outline: 0}.ui-dialog .ui-dialog-titlebar { padding: .4em 1em; position: relative}.ui-dialog .ui-dialog-title { float: left; margin: .1em 0; white-space: nowrap; width: 90%; overflow: hidden; text-overflow: ellipsis}.ui-dialog .ui-dialog-titlebar-close { position: absolute; right: .3em; top: 50%; width: 20px; margin: -10px 0 0 0; padding: 1px; height: 20px}.ui-dialog .ui-dialog-content { position: relative; border: 0; padding: .5em 1em; background: none; overflow: auto}.ui-dialog .ui-dialog-buttonpane { text-align: left; border-width: 1px 0 0 0; background-image: none; margin-top: .5em; padding: .3em 1em .5em .4em}.ui-dialog .ui-dialog-buttonpane .ui-dialog-buttonset { float: right}.ui-dialog .ui-dialog-buttonpane button { margin: .5em .4em .5em 0; cursor: pointer}.ui-dialog .ui-resizable-n { height: 2px; top: 0}.ui-dialog .ui-resizable-e { width: 2px; right: 0}.ui-dialog .ui-resizable-s { height: 2px; bottom: 0}.ui-dialog .ui-resizable-w { width: 2px; left: 0}.ui-dialog .ui-resizable-se, .ui-dialog .ui-resizable-sw, .ui-dialog .ui-resizable-ne, .ui-dialog .ui-resizable-nw { width: 7px; height: 7px}.ui-dialog .ui-resizable-se { right: 0; bottom: 0}.ui-dialog .ui-resizable-sw { left: 0; bottom: 0}.ui-dialog .ui-resizable-ne { right: 0; top: 0}.ui-dialog .ui-resizable-nw { left: 0; top: 0}.ui-draggable .ui-dialog-titlebar { cursor: move}.ui-progressbar { height: 2em; text-align: left; overflow: hidden}.ui-progressbar .ui-progressbar-value { margin: -1px; height: 100%}.ui-progressbar .ui-progressbar-overlay { background: url(\"\"); height: 100%; filter: alpha(opacity=25); opacity: 0.25}.ui-progressbar-indeterminate .ui-progressbar-value { background-image: none}.ui-selectmenu-menu { padding: 0; margin: 0; position: absolute; top: 0; left: 0; display: none}.ui-selectmenu-menu .ui-menu { overflow: auto; overflow-x: hidden; padding-bottom: 1px}.ui-selectmenu-menu .ui-menu .ui-selectmenu-optgroup { font-size: 1em; font-weight: bold; line-height: 1.5; padding: 2px 0.4em; margin: 0.5em 0 0 0; height: auto; border: 0}.ui-selectmenu-open { display: block}.ui-selectmenu-text { display: block; margin-right: 20px; overflow: hidden; text-overflow: ellipsis}.ui-selectmenu-button.ui-button { text-align: left; white-space: nowrap; width: 14em}.ui-selectmenu-icon.ui-icon { float: right; margin-top: 0}.ui-slider { position: relative; text-align: left}.ui-slider .ui-slider-handle { position: absolute; z-index: 2; width: 1.2em; height: 1.2em; cursor: default; -ms-touch-action: none; touch-action: none}.ui-slider .ui-slider-range { position: absolute; z-index: 1; font-size: .7em; display: block; border: 0; background-position: 0 0}.ui-slider.ui-state-disabled .ui-slider-handle, .ui-slider.ui-state-disabled .ui-slider-range { filter: inherit}.ui-slider-horizontal { height: .8em}.ui-slider-horizontal .ui-slider-handle { top: -.3em; margin-left: -.6em}.ui-slider-horizontal .ui-slider-range { top: 0; height: 100%}.ui-slider-horizontal .ui-slider-range-min { left: 0}.ui-slider-horizontal .ui-slider-range-max { right: 0}.ui-slider-vertical { width: .8em; height: 100px}.ui-slider-vertical .ui-slider-handle { left: -.3em; margin-left: 0; margin-bottom: -.6em}.ui-slider-vertical .ui-slider-range { left: 0; width: 100%}.ui-slider-vertical .ui-slider-range-min { bottom: 0}.ui-slider-vertical .ui-slider-range-max { top: 0}.ui-spinner { position: relative; display: inline-block; overflow: hidden; padding: 0; vertical-align: middle}.ui-spinner-input { border: none; background: none; color: inherit; padding: .222em 0; margin: .2em 0; vertical-align: middle; margin-left: .4em; margin-right: 2em}.ui-spinner-button { width: 1.6em; height: 50%; font-size: .5em; padding: 0; margin: 0; text-align: center; position: absolute; cursor: default; display: block; overflow: hidden; right: 0}.ui-spinner a.ui-spinner-button { border-top-style: none; border-bottom-style: none; border-right-style: none}.ui-spinner-up { top: 0}.ui-spinner-down { bottom: 0}.ui-tabs { position: relative; padding: .2em}.ui-tabs .ui-tabs-nav { margin: 0; padding: .2em .2em 0}.ui-tabs .ui-tabs-nav li { list-style: none; float: left; position: relative; top: 0; margin: 1px .2em 0 0; border-bottom-width: 0; padding: 0; white-space: nowrap}.ui-tabs .ui-tabs-nav .ui-tabs-anchor { float: left; padding: .5em 1em; text-decoration: none}.ui-tabs .ui-tabs-nav li.ui-tabs-active { margin-bottom: -1px; padding-bottom: 1px}.ui-tabs .ui-tabs-nav li.ui-tabs-active .ui-tabs-anchor, .ui-tabs .ui-tabs-nav li.ui-state-disabled .ui-tabs-anchor, .ui-tabs .ui-tabs-nav li.ui-tabs-loading .ui-tabs-anchor { cursor: text}.ui-tabs-collapsible .ui-tabs-nav li.ui-tabs-active .ui-tabs-anchor { cursor: pointer}.ui-tabs .ui-tabs-panel { display: block; border-width: 0; padding: 1em 1.4em; background: none}.ui-tooltip { padding: 8px; position: absolute; z-index: 9999; max-width: 300px}body .ui-tooltip { border-width: 2px}.ui-widget { font-family: Trebuchet MS, Tahoma, Verdana, Arial, sans-serif; font-size: 1.1em}.ui-widget .ui-widget { font-size: 1em}.ui-widget input, .ui-widget select, .ui-widget textarea, .ui-widget button { font-family: Trebuchet MS, Tahoma, Verdana, Arial, sans-serif; font-size: 1em}.ui-widget.ui-widget-content { border: 1px solid #ccc}.ui-widget-content { border: 1px solid #ccc; background: #eee url(\"../image/ui-bg_highlight-soft_100_efefef_1x100.png\") 50% top repeat-x; color: #333}.ui-widget-content a { color: #333}.ui-widget-header { border: 1px solid #e78f08; background: #f6a828 url(\"../image/ui-bg_gloss-wave_35_f6a828_500x100.png\") 50% 50% repeat-x; color: #fff; font-weight: bold}.ui-widget-header a { color: #fff}.ui-state-default, .ui-widget-content .ui-state-default, .ui-widget-header .ui-state-default, .ui-button, html .ui-button.ui-state-disabled:hover, html .ui-button.ui-state-disabled:active { border: 1px solid #ccc; background: #f6f6f6 url(\"../image/ui-bg_glass_100_f6f6f6_1x400.png\") 50% 50% repeat-x; font-weight: bold; color: #1c94c4}.ui-state-default a, .ui-state-default a:link, .ui-state-default a:visited, a.ui-button, a:link.ui-button, a:visited.ui-button, .ui-button { color: #1c94c4; text-decoration: none}.ui-state-hover, .ui-widget-content .ui-state-hover, .ui-widget-header .ui-state-hover, .ui-state-focus, .ui-widget-content .ui-state-focus, .ui-widget-header .ui-state-focus, .ui-button:hover, .ui-button:focus { border: 1px solid #fbcb09; background: #fdf5ce url(\"../image/ui-bg_glass_100_fdf5ce_1x400.png\") 50% 50% repeat-x; font-weight: bold; color: #c77405}.ui-state-hover a, .ui-state-hover a:hover, .ui-state-hover a:link, .ui-state-hover a:visited, .ui-state-focus a, .ui-state-focus a:hover, .ui-state-focus a:link, .ui-state-focus a:visited, a.ui-button:hover, a.ui-button:focus { color: #c77405; text-decoration: none}.ui-visual-focus { box-shadow: 0 0 3px 1px rgb(94, 158, 214)}.ui-state-active, .ui-widget-content .ui-state-active, .ui-widget-header .ui-state-active, a.ui-button:active, .ui-button:active, .ui-button.ui-state-active:hover { border: 1px solid #fbd850; background: #fff url(\"../image/ui-bg_glass_65_ffffff_1x400.png\") 50% 50% repeat-x; font-weight: bold; color: #eb8f00}.ui-icon-background, .ui-state-active .ui-icon-background { border: #fbd850; background-color: #eb8f00}.ui-state-active a, .ui-state-active a:link, .ui-state-active a:visited { color: #eb8f00; text-decoration: none}.ui-state-highlight, .ui-widget-content .ui-state-highlight, .ui-widget-header .ui-state-highlight { border: 1px solid #fed22f; background: #ffe45c url(\"../image/ui-bg_highlight-soft_75_ffe45c_1x100.png\") 50% top repeat-x; color: #363636}.ui-state-checked { border: 1px solid #fed22f; background: #ffe45c}.ui-state-highlight a, .ui-widget-content .ui-state-highlight a, .ui-widget-header .ui-state-highlight a { color: #363636}.ui-state-error, .ui-widget-content .ui-state-error, .ui-widget-header .ui-state-error { border: 1px solid #cd0a0a; background: #b81900 url(\"../image/ui-bg_diagonals-thick_18_b81900_40x40.png\") 50% 50% repeat; color: #fff}.ui-state-error a, .ui-widget-content .ui-state-error a, .ui-widget-header .ui-state-error a { color: #fff}.ui-state-error-text, .ui-widget-content .ui-state-error-text, .ui-widget-header .ui-state-error-text { color: #fff}.ui-priority-primary, .ui-widget-content .ui-priority-primary, .ui-widget-header .ui-priority-primary { font-weight: bold}.ui-priority-secondary, .ui-widget-content .ui-priority-secondary, .ui-widget-header .ui-priority-secondary { opacity: .7; filter: Alpha(Opacity=70); font-weight: normal}.ui-state-disabled, .ui-widget-content .ui-state-disabled, .ui-widget-header .ui-state-disabled { opacity: .35; filter: Alpha(Opacity=35); background-image: none}.ui-state-disabled .ui-icon { filter: Alpha(Opacity=35)}.ui-icon { width: 16px; height: 16px}.ui-icon, .ui-widget-content .ui-icon { background-image: url(\"../image/ui-icons_222222_256x240.png\")}.ui-widget-header .ui-icon { background-image: url(\"../image/ui-icons_ffffff_256x240.png\")}.ui-state-hover .ui-icon, .ui-state-focus .ui-icon, .ui-button:hover .ui-icon, .ui-button:focus .ui-icon { background-image: url(\"../image/ui-icons_ef8c08_256x240.png\")}.ui-state-active .ui-icon, .ui-button:active .ui-icon { background-image: url(\"../image/ui-icons_ef8c08_256x240.png\")}.ui-state-highlight .ui-icon, .ui-button .ui-state-highlight.ui-icon { background-image: url(\"../image/ui-icons_228ef1_256x240.png\")}.ui-state-error .ui-icon, .ui-state-error-text .ui-icon { background-image: url(\"../image/ui-icons_ffd27a_256x240.png\")}.ui-button .ui-icon { background-image: url(\"../image/ui-icons_ef8c08_256x240.png\")}.ui-icon-blank { background-position: 16px 16px}.ui-icon-caret-1-n { background-position: 0 0}.ui-icon-caret-1-ne { background-position: -16px 0}.ui-icon-caret-1-e { background-position: -32px 0}.ui-icon-caret-1-se { background-position: -48px 0}.ui-icon-caret-1-s { background-position: -65px 0}.ui-icon-caret-1-sw { background-position: -80px 0}.ui-icon-caret-1-w { background-position: -96px 0}.ui-icon-caret-1-nw { background-position: -112px 0}.ui-icon-caret-2-n-s { background-position: -128px 0}.ui-icon-caret-2-e-w { background-position: -144px 0}.ui-icon-triangle-1-n { background-position: 0 -16px}.ui-icon-triangle-1-ne { background-position: -16px -16px}.ui-icon-triangle-1-e { background-position: -32px -16px}.ui-icon-triangle-1-se { background-position: -48px -16px}.ui-icon-triangle-1-s { background-position: -65px -16px}.ui-icon-triangle-1-sw { background-position: -80px -16px}.ui-icon-triangle-1-w { background-position: -96px -16px}.ui-icon-triangle-1-nw { background-position: -112px -16px}.ui-icon-triangle-2-n-s { background-position: -128px -16px}.ui-icon-triangle-2-e-w { background-position: -144px -16px}.ui-icon-arrow-1-n { background-position: 0 -32px}.ui-icon-arrow-1-ne { background-position: -16px -32px}.ui-icon-arrow-1-e { background-position: -32px -32px}.ui-icon-arrow-1-se { background-position: -48px -32px}.ui-icon-arrow-1-s { background-position: -65px -32px}.ui-icon-arrow-1-sw { background-position: -80px -32px}.ui-icon-arrow-1-w { background-position: -96px -32px}.ui-icon-arrow-1-nw { background-position: -112px -32px}.ui-icon-arrow-2-n-s { background-position: -128px -32px}.ui-icon-arrow-2-ne-sw { background-position: -144px -32px}.ui-icon-arrow-2-e-w { background-position: -160px -32px}.ui-icon-arrow-2-se-nw { background-position: -176px -32px}.ui-icon-arrowstop-1-n { background-position: -192px -32px}.ui-icon-arrowstop-1-e { background-position: -208px -32px}.ui-icon-arrowstop-1-s { background-position: -224px -32px}.ui-icon-arrowstop-1-w { background-position: -240px -32px}.ui-icon-arrowthick-1-n { background-position: 1px -48px}.ui-icon-arrowthick-1-ne { background-position: -16px -48px}.ui-icon-arrowthick-1-e { background-position: -32px -48px}.ui-icon-arrowthick-1-se { background-position: -48px -48px}.ui-icon-arrowthick-1-s { background-position: -64px -48px}.ui-icon-arrowthick-1-sw { background-position: -80px -48px}.ui-icon-arrowthick-1-w { background-position: -96px -48px}.ui-icon-arrowthick-1-nw { background-position: -112px -48px}.ui-icon-arrowthick-2-n-s { background-position: -128px -48px}.ui-icon-arrowthick-2-ne-sw { background-position: -144px -48px}.ui-icon-arrowthick-2-e-w { background-position: -160px -48px}.ui-icon-arrowthick-2-se-nw { background-position: -176px -48px}.ui-icon-arrowthickstop-1-n { background-position: -192px -48px}.ui-icon-arrowthickstop-1-e { background-position: -208px -48px}.ui-icon-arrowthickstop-1-s { background-position: -224px -48px}.ui-icon-arrowthickstop-1-w { background-position: -240px -48px}.ui-icon-arrowreturnthick-1-w { background-position: 0 -64px}.ui-icon-arrowreturnthick-1-n { background-position: -16px -64px}.ui-icon-arrowreturnthick-1-e { background-position: -32px -64px}.ui-icon-arrowreturnthick-1-s { background-position: -48px -64px}.ui-icon-arrowreturn-1-w { background-position: -64px -64px}.ui-icon-arrowreturn-1-n { background-position: -80px -64px}.ui-icon-arrowreturn-1-e { background-position: -96px -64px}.ui-icon-arrowreturn-1-s { background-position: -112px -64px}.ui-icon-arrowrefresh-1-w { background-position: -128px -64px}.ui-icon-arrowrefresh-1-n { background-position: -144px -64px}.ui-icon-arrowrefresh-1-e { background-position: -160px -64px}.ui-icon-arrowrefresh-1-s { background-position: -176px -64px}.ui-icon-arrow-4 { background-position: 0 -80px}.ui-icon-arrow-4-diag { background-position: -16px -80px}.ui-icon-extlink { background-position: -32px -80px}.ui-icon-newwin { background-position: -48px -80px}.ui-icon-refresh { background-position: -64px -80px}.ui-icon-shuffle { background-position: -80px -80px}.ui-icon-transfer-e-w { background-position: -96px -80px}.ui-icon-transferthick-e-w { background-position: -112px -80px}.ui-icon-folder-collapsed { background-position: 0 -96px}.ui-icon-folder-open { background-position: -16px -96px}.ui-icon-document { background-position: -32px -96px}.ui-icon-document-b { background-position: -48px -96px}.ui-icon-note { background-position: -64px -96px}.ui-icon-mail-closed { background-position: -80px -96px}.ui-icon-mail-open { background-position: -96px -96px}.ui-icon-suitcase { background-position: -112px -96px}.ui-icon-comment { background-position: -128px -96px}.ui-icon-person { background-position: -144px -96px}.ui-icon-print { background-position: -160px -96px}.ui-icon-trash { background-position: -176px -96px}.ui-icon-locked { background-position: -192px -96px}.ui-icon-unlocked { background-position: -208px -96px}.ui-icon-bookmark { background-position: -224px -96px}.ui-icon-tag { background-position: -240px -96px}.ui-icon-home { background-position: 0 -112px}.ui-icon-flag { background-position: -16px -112px}.ui-icon-calendar { background-position: -32px -112px}.ui-icon-cart { background-position: -48px -112px}.ui-icon-pencil { background-position: -64px -112px}.ui-icon-clock { background-position: -80px -112px}.ui-icon-disk { background-position: -96px -112px}.ui-icon-calculator { background-position: -112px -112px}.ui-icon-zoomin { background-position: -128px -112px}.ui-icon-zoomout { background-position: -144px -112px}.ui-icon-search { background-position: -160px -112px}.ui-icon-wrench { background-position: -176px -112px}.ui-icon-gear { background-position: -192px -112px}.ui-icon-heart { background-position: -208px -112px}.ui-icon-star { background-position: -224px -112px}.ui-icon-link { background-position: -240px -112px}.ui-icon-cancel { background-position: 0 -128px}.ui-icon-plus { background-position: -16px -128px}.ui-icon-plusthick { background-position: -32px -128px}.ui-icon-minus { background-position: -48px -128px}.ui-icon-minusthick { background-position: -64px -128px}.ui-icon-close { background-position: -80px -128px}.ui-icon-closethick { background-position: -96px -128px}.ui-icon-key { background-position: -112px -128px}.ui-icon-lightbulb { background-position: -128px -128px}.ui-icon-scissors { background-position: -144px -128px}.ui-icon-clipboard { background-position: -160px -128px}.ui-icon-copy { background-position: -176px -128px}.ui-icon-contact { background-position: -192px -128px}.ui-icon-image { background-position: -208px -128px}.ui-icon-video { background-position: -224px -128px}.ui-icon-script { background-position: -240px -128px}.ui-icon-alert { background-position: 0 -144px}.ui-icon-info { background-position: -16px -144px}.ui-icon-notice { background-position: -32px -144px}.ui-icon-help { background-position: -48px -144px}.ui-icon-check { background-position: -64px -144px}.ui-icon-bulvar { background-position: -80px -144px}.ui-icon-radio-on { background-position: -96px -144px}.ui-icon-radio-off { background-position: -112px -144px}.ui-icon-pin-w { background-position: -128px -144px}.ui-icon-pin-s { background-position: -144px -144px}.ui-icon-play { background-position: 0 -160px}.ui-icon-pause { background-position: -16px -160px}.ui-icon-seek-next { background-position: -32px -160px}.ui-icon-seek-prev { background-position: -48px -160px}.ui-icon-seek-end { background-position: -64px -160px}.ui-icon-seek-start { background-position: -80px -160px}.ui-icon-seek-first { background-position: -80px -160px}.ui-icon-stop { background-position: -96px -160px}.ui-icon-eject { background-position: -112px -160px}.ui-icon-volume-off { background-position: -128px -160px}.ui-icon-volume-on { background-position: -144px -160px}.ui-icon-power { background-position: 0 -176px}.ui-icon-signal-diag { background-position: -16px -176px}.ui-icon-signal { background-position: -32px -176px}.ui-icon-battery-0 { background-position: -48px -176px}.ui-icon-battery-1 { background-position: -64px -176px}.ui-icon-battery-2 { background-position: -80px -176px}.ui-icon-battery-3 { background-position: -96px -176px}.ui-icon-circle-plus { background-position: 0 -192px}.ui-icon-circle-minus { background-position: -16px -192px}.ui-icon-circle-close { background-position: -32px -192px}.ui-icon-circle-triangle-e { background-position: -48px -192px}.ui-icon-circle-triangle-s { background-position: -64px -192px}.ui-icon-circle-triangle-w { background-position: -80px -192px}.ui-icon-circle-triangle-n { background-position: -96px -192px}.ui-icon-circle-arrow-e { background-position: -112px -192px}.ui-icon-circle-arrow-s { background-position: -128px -192px}.ui-icon-circle-arrow-w { background-position: -144px -192px}.ui-icon-circle-arrow-n { background-position: -160px -192px}.ui-icon-circle-zoomin { background-position: -176px -192px}.ui-icon-circle-zoomout { background-position: -192px -192px}.ui-icon-circle-check { background-position: -208px -192px}.ui-icon-circlesmall-plus { background-position: 0 -208px}.ui-icon-circlesmall-minus { background-position: -16px -208px}.ui-icon-circlesmall-close { background-position: -32px -208px}.ui-icon-squaresmall-plus { background-position: -48px -208px}.ui-icon-squaresmall-minus { background-position: -64px -208px}.ui-icon-squaresmall-close { background-position: -80px -208px}.ui-icon-grip-dotted-vertical { background-position: 0 -224px}.ui-icon-grip-dotted-horizontal { background-position: -16px -224px}.ui-icon-grip-solid-vertical { background-position: -32px -224px}.ui-icon-grip-solid-horizontal { background-position: -48px -224px}.ui-icon-gripsmall-diagonal-se { background-position: -64px -224px}.ui-icon-grip-diagonal-se { background-position: -80px -224px}.ui-corner-all, .ui-corner-top, .ui-corner-left, .ui-corner-tl { border-top-left-radius: 4px}.ui-corner-all, .ui-corner-top, .ui-corner-right, .ui-corner-tr { border-top-right-radius: 4px}.ui-corner-all, .ui-corner-bottom, .ui-corner-left, .ui-corner-bl { border-bottom-left-radius: 4px}.ui-corner-all, .ui-corner-bottom, .ui-corner-right, .ui-corner-br { border-bottom-right-radius: 4px}.ui-widget-overlay { background: #666 url(\"../image/ui-bg_diagonals-thick_20_666666_40x40.png\") 50% 50% repeat; opacity: .5; filter: Alpha(Opacity=50)}.ui-widget-shadow { -webkit-box-shadow: -5px -5px 5px #000; box-shadow: -5px -5px 5px #000}");
            System.out.println("write to file success : " + file.getPath());
        } catch (IOException e) {
            e.printStackTrace();
        } finally {
            MybatisUtilCommon.closeBufferWriterAndFileOutputStream(fileOutputStream, bufferedWriter);
        }
    }

    public static void writeCommonPageCommonJsSha256Js(String htmlPath, String serverUrl) {
        File file = null;
        OutputStream fileOutputStream = null;
        BufferedWriter bufferedWriter = null;
        try {
            File folder = new File(htmlPath + "/common/page-common/js/");
            folder.mkdirs();
            file = new File(htmlPath + "/common/page-common/js/sha256.js");
            //如果文件不存在，则创建文件，如果已存在，则覆盖
            file.createNewFile();
            fileOutputStream = new FileOutputStream(file);
            bufferedWriter = new BufferedWriter(new OutputStreamWriter(fileOutputStream, "utf-8"));
            bufferedWriter.write("function sha256(s){var chrsz=8;var hexcase=0;function safe_add(x,y){var lsw=(x&0xFFFF)+(y&0xFFFF);var msw=(x>>16)+(y>>16)+(lsw>>16);return(msw<<16)|(lsw&0xFFFF)}function S(X,n){return(X>>>n)|(X<<(32-n))}function R(X,n){return(X>>>n)}function Ch(x,y,z){return((x&y)^((~x)&z))}function Maj(x,y,z){return((x&y)^(x&z)^(y&z))}function Sigma0256(x){return(S(x,2)^S(x,13)^S(x,22))}function Sigma1256(x){return(S(x,6)^S(x,11)^S(x,25))}function Gamma0256(x){return(S(x,7)^S(x,18)^R(x,3))}function Gamma1256(x){return(S(x,17)^S(x,19)^R(x,10))}function core_sha256(m,l){var K=new Array(0x428A2F98,0x71374491,0xB5C0FBCF,0xE9B5DBA5,0x3956C25B,0x59F111F1,0x923F82A4,0xAB1C5ED5,0xD807AA98,0x12835B01,0x243185BE,0x550C7DC3,0x72BE5D74,0x80DEB1FE,0x9BDC06A7,0xC19BF174,0xE49B69C1,0xEFBE4786,0xFC19DC6,0x240CA1CC,0x2DE92C6F,0x4A7484AA,0x5CB0A9DC,0x76F988DA,0x983E5152,0xA831C66D,0xB00327C8,0xBF597FC7,0xC6E00BF3,0xD5A79147,0x6CA6351,0x14292967,0x27B70A85,0x2E1B2138,0x4D2C6DFC,0x53380D13,0x650A7354,0x766A0ABB,0x81C2C92E,0x92722C85,0xA2BFE8A1,0xA81A664B,0xC24B8B70,0xC76C51A3,0xD192E819,0xD6990624,0xF40E3585,0x106AA070,0x19A4C116,0x1E376C08,0x2748774C,0x34B0BCB5,0x391C0CB3,0x4ED8AA4A,0x5B9CCA4F,0x682E6FF3,0x748F82EE,0x78A5636F,0x84C87814,0x8CC70208,0x90BEFFFA,0xA4506CEB,0xBEF9A3F7,0xC67178F2);var HASH=new Array(0x6A09E667,0xBB67AE85,0x3C6EF372,0xA54FF53A,0x510E527F,0x9B05688C,0x1F83D9AB,0x5BE0CD19);var W=new Array(64);var a,b,c,d,e,f,g,h,i,j;var T1,T2;m[l>>5]|=0x80<<(24-l%32);m[((l+64>>9)<<4)+15]=l;for(var i=0;i<m.length;i+=16){a=HASH[0];b=HASH[1];c=HASH[2];d=HASH[3];e=HASH[4];f=HASH[5];g=HASH[6];h=HASH[7];for(var j=0;j<64;j++){if(j<16)W[j]=m[j+i];else W[j]=safe_add(safe_add(safe_add(Gamma1256(W[j-2]),W[j-7]),Gamma0256(W[j-15])),W[j-16]);T1=safe_add(safe_add(safe_add(safe_add(h,Sigma1256(e)),Ch(e,f,g)),K[j]),W[j]);T2=safe_add(Sigma0256(a),Maj(a,b,c));h=g;g=f;f=e;e=safe_add(d,T1);d=c;c=b;b=a;a=safe_add(T1,T2)}HASH[0]=safe_add(a,HASH[0]);HASH[1]=safe_add(b,HASH[1]);HASH[2]=safe_add(c,HASH[2]);HASH[3]=safe_add(d,HASH[3]);HASH[4]=safe_add(e,HASH[4]);HASH[5]=safe_add(f,HASH[5]);HASH[6]=safe_add(g,HASH[6]);HASH[7]=safe_add(h,HASH[7])}return HASH}function str2binb(str){var bin=Array();var mask=(1<<chrsz)-1;for(var i=0;i<str.length*chrsz;i+=chrsz){bin[i>>5]|=(str.charCodeAt(i/chrsz)&mask)<<(24-i%32)}return bin}function Utf8Encode(string){string=string.replace(/\\r\\n/g,\"\\n\");var utftext=\"\";for(var n=0;n<string.length;n++){var c=string.charCodeAt(n);if(c<128){utftext+=String.fromCharCode(c)}else if((c>127)&&(c<2048)){utftext+=String.fromCharCode((c>>6)|192);utftext+=String.fromCharCode((c&63)|128)}else{utftext+=String.fromCharCode((c>>12)|224);utftext+=String.fromCharCode(((c>>6)&63)|128);utftext+=String.fromCharCode((c&63)|128)}}return utftext}function binb2hex(binarray){var hex_tab=hexcase?\"0123456789ABCDEF\":\"0123456789abcdef\";var str=\"\";for(var i=0;i<binarray.length*4;i++){str+=hex_tab.charAt((binarray[i>>2]>>((3-i%4)*8+4))&0xF)+hex_tab.charAt((binarray[i>>2]>>((3-i%4)*8))&0xF)}return str}s=Utf8Encode(s);return binb2hex(core_sha256(str2binb(s),s.length*chrsz))}");
            System.out.println("write to file success : " + file.getPath());
        } catch (IOException e) {
            e.printStackTrace();
        } finally {
            MybatisUtilCommon.closeBufferWriterAndFileOutputStream(fileOutputStream, bufferedWriter);
        }
    }

    public static void writeCommonPageCommonJsJjlcJs(String htmlPath, String serverUrl) {
        File file = null;
        OutputStream fileOutputStream = null;
        BufferedWriter bufferedWriter = null;
        try {
            File folder = new File(htmlPath + "/common/page-common/js/");
            folder.mkdirs();
            file = new File(htmlPath + "/common/page-common/js/jcompress.js");
            //如果文件不存在，则创建文件，如果已存在，则覆盖
            file.createNewFile();
            fileOutputStream = new FileOutputStream(file);
            bufferedWriter = new BufferedWriter(new OutputStreamWriter(fileOutputStream, "utf-8"));
            bufferedWriter.write("!function(e){\"use strict\";function t(e){var t,n=[],r={};for(t in e)n.push([t,e[t]]);n.sort(function(e,t){return t[1]-e[1]});for(t in n)r[n[t][0]]=n[t][1];return r}function n(e){var t,r=e[e" +
                    ".length-1],o=e.substring(0,e.length-1);return\"undefined\"==typeof r?t=\"a\":\"z\"===r?t=\"A\":\"Z\"===r?(t=\"a\",o=\"\"!==o?n(o):\"a\"):t=String.fromCharCode(r.charCodeAt(0)+1),r=t,o+r}function r(e){var r,o,i={}," +
                    "f=\"\",d=e.match(u);for(r in d)d[r].length>f.length+2&&(\"undefined\"!=typeof i[d[r]]?i[d[r]]+=1:i[d[r]]=0);o=t(i);for(r in o)f=n(f),o[r]=a+f+a;return o}function o(e,t){var n,r;for(n in t)r=new RegExp(n,\"g\"),e=e" +
                    ".replace(r,t[n]);return e}function i(e,t){var n,r;for(n in t)r=new RegExp(t[n],\"g\"),e=e.replace(r,n);return e}function f(){this.setItem=function(e,t,n){var i,f,u;return(\"undefined\"==typeof n||\"no-beautify\"!==n)" +
                    "&&(f=JSON.parse(t),t=JSON.stringify(f)),u=r(t),i=o(t,u),\"undefined\"!=typeof n&&\"local-dict\"===n?d[e]=u:localStorage.setItem(e,i),\"undefined\"==typeof d[e]&&localStorage.setItem(\"d_\"+e,JSON.stringify(u)),i}," +
                    "this.getItem=function(e){var t,n;return t=localStorage.getItem(e),n=\"undefined\"==typeof d[e]?JSON.parse(localStorage.getItem(\"d_\"+e)):d[e],i(t,n)},this.getDict=function(e){var t;return t=\"undefined\"==typeof " +
                    "d[e]?JSON.parse(localStorage.getItem(\"d_\"+e)):d[e]},this.setDict=function(e,t,n){\"undefined\"==typeof n?localStorage.setItem(\"d_\"+e,t):d[e]=t}}var u=/\\\"[a-zA-Z0-9]*\\\":/g,a=\"£\",d={};\"undefined\"!=typeof " +
                    "define&&define.amd?define([],function(){return new f}):\"undefined\"!=typeof module&&module.exports?module.exports=new f:e.JCOMPRESS=new f}(this);");
            System.out.println("write to file success : " + file.getPath());
        } catch (IOException e) {
            e.printStackTrace();
        } finally {
            MybatisUtilCommon.closeBufferWriterAndFileOutputStream(fileOutputStream, bufferedWriter);
        }
    }

    public static void writeCommonPageCommonImageBlankImageAll(String htmlPath, String serverUrl) {
        writeCommonPageCommonImageBlankImage(htmlPath, serverUrl, "ui-bg_diagonals-thick_18_b81900_40x40.png");
        writeCommonPageCommonImageBlankImage(htmlPath, serverUrl, "ui-bg_diagonals-thick_20_666666_40x40.png");
        writeCommonPageCommonImageBlankImage(htmlPath, serverUrl, "ui-bg_glass_65_ffffff_1x400.png");
        writeCommonPageCommonImageBlankImage(htmlPath, serverUrl, "ui-bg_glass_100_f6f6f6_1x400.png");
        writeCommonPageCommonImageBlankImage(htmlPath, serverUrl, "ui-bg_glass_100_fdf5ce_1x400.png");
        writeCommonPageCommonImageBlankImage(htmlPath, serverUrl, "ui-bg_gloss-wave_35_f6a828_500x100.png");
        writeCommonPageCommonImageBlankImage(htmlPath, serverUrl, "ui-bg_highlight-soft_75_ffe45c_1x100.png");
        writeCommonPageCommonImageBlankImage(htmlPath, serverUrl, "ui-bg_highlight-soft_100_efefef_1x100.png");
        writeCommonPageCommonImageBlankImage(htmlPath, serverUrl, "ui-icons_228ef1_256x240.png");
        writeCommonPageCommonImageBlankImage(htmlPath, serverUrl, "ui-icons_222222_256x240.png");
        writeCommonPageCommonImageBlankImage(htmlPath, serverUrl, "ui-icons_ef8c08_256x240.png");
        writeCommonPageCommonImageBlankImage(htmlPath, serverUrl, "ui-icons_ffd27a_256x240.png");
        writeCommonPageCommonImageBlankImage(htmlPath, serverUrl, "ui-icons_ffffff_256x240.png");
    }

    public static void writeCommonPageCommonImageBlankImage(String htmlPath, String serverUrl, String fileName) {
        File file = null;
        OutputStream fileOutputStream = null;
        BufferedWriter bufferedWriter = null;
        try {
            File folder = new File(htmlPath + "/common/page-common/image/");
            folder.mkdirs();
            file = new File(htmlPath + "/common/page-common/image/" + fileName);
            //如果文件不存在，则创建文件，如果已存在，则覆盖
            file.createNewFile();
            fileOutputStream = new FileOutputStream(file);
            bufferedWriter = new BufferedWriter(new OutputStreamWriter(fileOutputStream, "utf-8"));
            bufferedWriter.write("");
            System.out.println("write to file success : " + file.getPath());
        } catch (IOException e) {
            e.printStackTrace();
        } finally {
            MybatisUtilCommon.closeBufferWriterAndFileOutputStream(fileOutputStream, bufferedWriter);
        }
    }

    public static void writeCommonPageShareCssCommonCss(String htmlPath, String serverUrl) {
        File file = null;
        OutputStream fileOutputStream = null;
        BufferedWriter bufferedWriter = null;
        try {
            File folder = new File(htmlPath + "/common/page-share/css");
            folder.mkdirs();
            file = new File(htmlPath + "/common/page-share/css/common.css");
            //如果文件不存在，则创建文件，如果已存在，则覆盖
            file.createNewFile();
            fileOutputStream = new FileOutputStream(file);
            bufferedWriter = new BufferedWriter(new OutputStreamWriter(fileOutputStream, "utf-8"));
            bufferedWriter.write("");
            System.out.println("write to file success : " + file.getPath());
        } catch (IOException e) {
            e.printStackTrace();
        } finally {
            MybatisUtilCommon.closeBufferWriterAndFileOutputStream(fileOutputStream, bufferedWriter);
        }
    }

    public static void writeCommonPageShareJsCommonValueJs(String htmlPath, String serverUrl) {
        File file = null;
        OutputStream fileOutputStream = null;
        BufferedWriter bufferedWriter = null;
        try {
            File folder = new File(htmlPath + "/common/page-share/js");
            folder.mkdirs();
            file = new File(htmlPath + "/common/page-share/js/common-value.js");
            //如果文件不存在，则创建文件，如果已存在，则覆盖
            file.createNewFile();
            fileOutputStream = new FileOutputStream(file);
            bufferedWriter = new BufferedWriter(new OutputStreamWriter(fileOutputStream, "utf-8"));
            bufferedWriter.write(
                    "var ERROR_MESSAGE_CANNOT_CONNECT_TO_SERVER = \"你刷新的太快了，请坐下来喝杯咖啡吧！\";\n" +
                            "var loadingImage = \"<image title='加载中...' class='class-has-title class-image-icon class-image-icon-loading class-image-icon-loading-2' src=''/>\";\n" +
//                            "var yesImage = \"<image class='class-image-icon class-image-icon-yes' title='确认' src='' />\";\n" +
//                            "var noImage = \"<image class='class-image-icon class-image-icon-no' title='否' src=''  />\";\n" +
//                            "var searchImage = \"<image    class='class-image-icon class-image-icon-search' title='查找' src='' />\";\n" +
                            "\n" +
                            "\n");
            System.out.println("write to file success : " + file.getPath());
        } catch (IOException e) {
            e.printStackTrace();
        } finally {
            MybatisUtilCommon.closeBufferWriterAndFileOutputStream(fileOutputStream, bufferedWriter);
        }
    }

    public static void writeCommonPageShareJsCommonFunctionJs(String htmlPath, String serverUrl, String fileUploadServer) {
        File file = null;
        OutputStream fileOutputStream = null;
        BufferedWriter bufferedWriter = null;
        try {
            File folder = new File(htmlPath + "/common/page-share/js");
            folder.mkdirs();
            file = new File(htmlPath + "/common/page-share/js/common-function.js");
            //如果文件不存在，则创建文件，如果已存在，则覆盖
            file.createNewFile();
            fileOutputStream = new FileOutputStream(file);
            bufferedWriter = new BufferedWriter(new OutputStreamWriter(fileOutputStream, "utf-8"));
            bufferedWriter.write("//------------------auto-load-function------------------\n" +
                    "$(function () {\n" +
                    "    showPictureClickFuntion();\n" +
                    "})\n" +
                    "\n" +
                    "//------------------description-function------------------\n" +
                    "\n" +
                    "var HashMap = function(){  \n" +
                    "    //定义长度  \n" +
                    "    var length = 0;  \n" +
                    "    //创建一个实例  \n" +
                    "    var obj = new Object();  \n" +
                    "  \n" +
                    "    this.isEmpty = function(){  \n" +
                    "        return length == 0;  \n" +
                    "    };  \n" +
                    "  \n" +
                    "    this.containsKey=function(key){  \n" +
                    "        return (key in obj);  \n" +
                    "    };  \n" +
                    "  \n" +
                    "    this.containsValue=function(value){  \n" +
                    "        for(var key in obj){  \n" +
                    "            if(obj[key] == value){  \n" +
                    "                return true;  \n" +
                    "            }  \n" +
                    "        }  \n" +
                    "        return false;  \n" +
                    "    };  \n" +
                    "  \n" +
                    "    this.put=function(key,value){  \n" +
                    "        if(!this.containsKey(key)){  \n" +
                    "            length++;  \n" +
                    "        }  \n" +
                    "        obj[key] = value;  \n" +
                    "    };  \n" +
                    "  \n" +
                    "    this.get=function(key){  \n" +
                    "        return this.containsKey(key)?obj[key]:null;  \n" +
                    "    };  \n" +
                    "  \n" +
                    "    this.remove=function(key){  \n" +
                    "        if(this.containsKey(key)&&(delete obj[key])){  \n" +
                    "            length--;  \n" +
                    "        }  \n" +
                    "    };  \n" +
                    "  \n" +
                    "    this.values=function(){  \n" +
                    "        var _values= new Array();  \n" +
                    "        for(var key in obj){  \n" +
                    "            _values.push(obj[key]);  \n" +
                    "        }  \n" +
                    "        return _values;  \n" +
                    "    };  \n" +
                    "  \n" +
                    "    this.keySet=function(){  \n" +
                    "        var _keys = new Array();  \n" +
                    "        for(var key in obj){  \n" +
                    "            _keys.push(key);  \n" +
                    "        }  \n" +
                    "        return _keys;  \n" +
                    "    };  \n" +
                    "  \n" +
                    "    this.size = function(){  \n" +
                    "        return length;  \n" +
                    "    };  \n" +
                    "  \n" +
                    "    this.clear = function(){  \n" +
                    "        length = 0;  \n" +
                    "        obj = new Object();  \n" +
                    "    };  \n" +
                    "}  \n" +
                    "\n" +
                    "var formatMoney =function(money, number)\n" +
                    "{\n" +
                    "   if(number==undefined){\n" +
                    "       number=0;\n" +
                    "   }\n" +
                    "   money = parseFloat((money + \"\").replace(/[^\\d\\.-]/g, \"\")).toFixed(number) + \"\";\n" +
                    "   var l = money.split(\".\")[0].split(\"\").reverse(),\n" +
                    "   r = money.split(\".\")[1];\n" +
                    "   t = \"\";\n" +
                    "   for(i = 0; i < l.length; i ++ )\n" +
                    "   {\n" +
                    "      t += l[i] + (((i + 1) % 3 == 0 && (i + 1) != l.length) ? \",\" : \"\");\n" +
                    "   }\n" +
                    "   return t.split(\"\").reverse().join(\"\") + (number==0?'':\".\" + r);\n" +
                    "}\n" +
                    "\n" +
                    "var getYesOrNoDescription = function (yesOrNo) {\n" +
                    "    if (yesOrNo == 0) {\n" +
                    "        return \"否\";\n" +
                    "    }\n" +
                    "    if (yesOrNo == 1) {\n" +
                    "        return \"是\";\n" +
                    "    }\n" +
                    "    return \"\";\n" +
                    "}\n" +
                    "\n" +
                    "//------------------common-function-can-use-every-js-file------------------\n" +
                    "\n" +
                    "" +
                    "\n" +
                    "var getLocalStorageItem = function (key) {\n" +
                    "    var data = JCOMPRESS.getItem(sha256(key));\n" +
                    "    if(data==undefined){\n" +
                    "        return undefined;\n" +
                    "    }\n" +
                    "    var dataJson = JSON.parse(data);\n" +
                    "    return dataJson.value;\n" +
                    "}\n" +
                    "\n" +
                    "var setLocalStorageItem = function (key, value) {\n" +
                    "    if (value != null && value != undefined) {\n" +
                    "        var data = {};\n" +
                    "        data.value=value;\n" +
                    "        JCOMPRESS.setItem(sha256(key), JSON.stringify(data));\n" +
                    "    }\n" +
                    "}\n" +
                    "\n" +
                    "var setLocalStorageObject = function (key, value) {\n" +
                    "    if (value != null && value != undefined) {\n" +
                    "        var data = {};\n" +
                    "        data.value=value;\n" +
                    "        JCOMPRESS.setItem(sha256(key), JSON.stringify(data));\n" +
                    "    }\n" +
                    "}\n" +
                    "\n" +
                    "var getLocalStorageObject = function (key) {\n" +
                    "    var data = JCOMPRESS.getItem(sha256(key));\n" +
                    "    if(data==undefined){\n" +
                    "        return undefined;\n" +
                    "    }\n" +
                    "    var dataJson = JSON.parse(data);\n" +
                    "    return dataJson.value;\n" +
                    "}\n" +
                    "\n" +
                    "var removeLocalStorageItem = function (key) {\n" +
                    "    localStorage.removeItem(\"d_\"+sha256(key));\n" +
                    "    localStorage.removeItem(sha256(key));\n" +
                    "}\n" +
                    "\n" +
                    "var base64Encode = function (str) {\n" +
                    "    return btoa(encodeURIComponent(str));\n" +
                    "}\n" +
                    "\n" +
                    "var base64Decode = function (str) {\n" +
                    "    if (str == null || str == undefined) {\n" +
                    "        return undefined;\n" +
                    "    }\n" +
                    "    return decodeURIComponent(atob(str));\n" +
                    "}\n" +
                    "\n" +
                    "var openWindow = function (url) {\n" +
                    "    window.open(url);\n" +
                    "}\n" +
                    "\n" +
                    "var showAlertFrameMultiple = function (message) {\n" +
                    "    var id = getRandomId();\n" +
                    "    $(\"body\").append(\"<div onclick=\\\"closeAlertFrame('\" + id + \"')\\\" \" +\n" +
                    "        \"style='z-index: 9999;position: absolute;top:0;left:0;width:100%;height:100%;' \" +\n" +
                    "        \"class='class-div-alert-frame class-div-alert-frame-\" + id + \" '>\" +\n" +
                    "        \"\" +\n" +
                    "        \"<div class='class-div-alert-frame-content'  onclick=\\\"closeAlertFrame('\" + id + \"')\\\" \" +\n" +
                    "        \"style='border-radius:26px;margin-left:33%;margin-top:10%;\" +\n" +
                    "        \"background-image: linear-gradient(to top,#EEEEEE,#FFFFFF);border:1px solid #666666;\" +\n" +
                    "        \"width:33%;padding:26px;color: #666666;overflow:hidden;'>\" +\n" +
                    "        \"<div class='class-div-alert-frame-content-message'  style='text-align:center;'>\" +\n" +
                    "        \"<span class='class-span-alert-frame-content-message' >\" + message + \"</span></div>\" +\n" +
                    "        \"</div>\" +\n" +
                    "        \"</div>\");\n" +
                    "    $(\"html,body\").animate({\n" +
                    "        scrollTop: 0\n" +
                    "    }, 0);\n" +
                    "}\n" +
                    "\n" +
                    "var showAlertFrame = function (message) {\n" +
                    "    var id = getRandomId();\n" +
                    "    $(\".class-div-alert-frame\").remove();\n" +
                    "    $(\"body\").append(\"<div onclick=\\\"closeAlertFrame('\" + id + \"')\\\" \" +\n" +
                    "        \"style='z-index: 9999;position: absolute;top:0;left:0;width:100%;height:100%;' \" +\n" +
                    "        \"class='class-div-alert-frame class-div-alert-frame-\" + id + \" '>\" +\n" +
                    "        \"\" +\n" +
                    "        \"<div class='class-div-alert-frame-content'  onclick=\\\"closeAlertFrame('\" + id + \"')\\\" \" +\n" +
                    "        \"style='border-radius:26px;margin-left:33%;margin-top:10%;\" +\n" +
                    "        \"background-image: linear-gradient(to top,#EEEEEE,#FFFFFF);border:1px solid #666666;\" +\n" +
                    "        \"width:33%;padding:26px;color: #666666;overflow:hidden;'>\" +\n" +
                    "        \"<div class='class-div-alert-frame-content-message'  style='text-align:center;'>\" +\n" +
                    "        \"<span class='class-span-alert-frame-content-message' >\" + message + \"</span></div>\" +\n" +
                    "        \"</div>\" +\n" +
                    "        \"</div>\");\n" +
                    "    $(\"html,body\").animate({\n" +
                    "        scrollTop: 0\n" +
                    "    }, 0);\n" +
                    "}\n" +
                    "\n" +
                    "var closeAlertFrame = function (id) {\n" +
                    "    $(\".class-div-alert-frame-\" + id).fadeOut(300, function () {\n" +
                    "        $(\".class-div-alert-frame-\" + id).remove();\n" +
                    "    });\n" +
                    "}\n" +
                    "\n" +
                    "var showPasswordFrame = function (obj) {\n" +
                    "    var offset = $(obj).offset();\n" +
                    "    var left = offset.left;\n" +
                    "    var top = offset.top;\n" +
                    "    var id = getRandomId();\n" +
                    "    $(\"body\").append(\"<div \" +\n" +
                    "        \"style='z-index: 9999;position: absolute;top:\" + top + \"px;left:\" + left + \"px;width:366px;padding:16px;\" +\n" +
                    "        \"background-image: linear-gradient(to top,#EEEEEE,#FFFFFF);border:1px solid #666666;border-radius:6px;\" +\n" +
                    "        \"' class='class-div-password-frame class-div-password-frame-\" + id + \" '>\" +\n" +
                    "        \"<span style='display: none' class='class-span-id-in-frame'>\" + id + \"</span>\" +\n" +
                    "        \"<input type='password' class='class-input class-input-password-in-frame class-input-password-in-frame-\" + id + \"' />\" +\n" +
                    "        \"<button class='class-button class-button-password class-button-password-this-frame-\" + id + \"'>确认</button>\" +\n" +
                    "        \"<button class='class-button class-button-close class-button-close-password-frame-\" + id + \"'>取消</button>\" +\n" +
                    "        \"</div>\");\n" +
                    "    $(\".class-button-password-this-frame-\" + id).click(function () {\n" +
                    "        $(obj).val(sha256($(\".class-input-password-in-frame\").val()));\n" +
                    "        closePasswordFrame($(\".class-span-id-in-frame\").html());\n" +
                    "    });\n" +
                    "    $(\".class-button-close-password-frame-\" + id).click(function () {\n" +
                    "        closePasswordFrame($(\".class-span-id-in-frame\").html());\n" +
                    "    });\n" +
                    "}\n" +
                    "\n" +
                    "var closePasswordFrame = function (id) {\n" +
                    "    $(\".class-div-password-frame-\" + id).fadeOut(300, function () {\n" +
                    "        $(\".class-div-password-frame-\" + id).remove();\n" +
                    "    });\n" +
                    "}\n" +
                    "\n" +
                    "var showUploadFrame = function (obj, type) {\n" +
                    "    var offset = $(obj).offset();\n" +
                    "    var left = offset.left;\n" +
                    "    var top = offset.top;\n" +
                    "    var id = getRandomId();\n" +
                    "    $(\"body\").append(\"<div \" +\n" +
                    "        \"style='z-index: 9999;position: absolute;top:\" + top + \"px;left:\" + left + \"px;width:366px;padding:16px;\" +\n" +
                    "        \"background-image: linear-gradient(to top,#EEEEEE,#FFFFFF);border:1px solid #666666;border-radius:6px;\" +\n" +
                    "        \"' class='class-div-upload-frame class-div-upload-frame-\" + id + \" '>\" +\n" +
                    "        \"<input type='file' class='class-input class-input-file class-input-file-\" + id + \"' />\" +\n" +
                    "        \"<button class='class-button class-button-upload class-button-upload-this-file-\" + id + \"'>上传</button>\" +\n" +
                    "        \"<button onclick=\\\"closeUploadFrame('\" + id + \"')\\\" class='class-button class-button-close class-button-close-upload-frame-\" + id + \"'>取消</button>\" +\n" +
                    "        \"</div>\");\n" +
                    "    $(\".class-button-upload-this-file-\" + id).click(function () {\n" +
                    "        var token = getLocalStorageItem(\"token\");\n" +
                    "        var formData = new FormData();\n" +
                    "        if ($(\".class-input-file-\" + id)[0].files[0] == undefined) {\n" +
                    "            showAlertFrame(\"你未选中文件\");\n" +
                    "            $(\".class-input-file-\" + id).focus();\n" +
                    "            return;\n" +
                    "        }\n" +
                    "        var file = $(\".class-input-file-\" + id)[0].files[0];\n" +
                    "        var name = file.name;\n" +
                    "        var names = name.split(\"\\.\");\n" +
                    "        var nameSuffix = names[names.length - 1];\n" +
                    "        nameSuffix = nameSuffix.toLowerCase();\n" +
                    "        if (type == \"video\") {\n" +
                    "            if (file.size > UPLOAD_VIDEO_SIZE_LIMIT) {\n" +
                    "                showAlertFrame(\"文件太大了，超过5M了!\");\n" +
                    "                return;\n" +
                    "            }\n" +
                    "            if (nameSuffix != \"mp4\") {\n" +
                    "                showAlertFrame(\"目前只支持mp4格式的视频，其他视频请用视频工具转换成mp4再上传!\");\n" +
                    "                return;\n" +
                    "            }\n" +
                    "        } else if (type == \"image\") {\n" +
                    "            if (file.size > UPLOAD_IMAGE_SIZE_LIMIT) {\n" +
                    "                showAlertFrame(\"文件太大了，超过0.5M了!\");\n" +
                    "                return;\n" +
                    "            }\n" +
                    "            if (nameSuffix != \"jpg\" && nameSuffix != \"jpeg\" && nameSuffix != \"bmp\" && nameSuffix != \"png\" && nameSuffix != \"svg\" && nameSuffix != \"tiff\") {\n" +
                    "                showAlertFrame(\"目前支持图片上传格式有jpg,jpeg,bmp,png,svg,tiff, 你上传的文件格式不在支持列表中\" + nameSuffix + \"!\");\n" +
                    "                return;\n" +
                    "            }\n" +
                    "        } else if (type == \"file\") {\n" +
                    "            if (file.size > UPLOAD_FILE_SIZE_LIMIT) {\n" +
                    "                showAlertFrame(\"文件太大了，超过1M了!\");\n" +
                    "                return;\n" +
                    "            }\n" +
                    "        }\n" +
                    "        showAlertFrame(\"上传中，请稍候\");\n" +
                    "        formData.append(\"file\", $(\".class-input-file-\" + id)[0].files[0]);\n" +
                    "        $.ajax({\n" +
                    "            type: 'post',\n" +
                    "            url: \"" + fileUploadServer + "\",\n" +
                    "            data: formData,\n" +
                    "            cache: false,\n" +
                    "            async: true,\n" +
                    "            headers: {\"token\": token},\n" +
                    "            processData: false,\n" +
                    "            contentType: false,\n" +
                    "            accept: \"application/json\",\n" +
                    "            success: function (res) {\n" +
                    "                if (res.status == 200) {\n" +
                    "                    $(\".class-show-upload-frame-\" + id).remove();\n" +
                    "                    $(obj).val(res.data.fileFullUrl);\n" +
                    "                    showAlertFrame(\"上传成功\");\n" +
                    "                    closeUploadFrame(id);\n" +
                    "                    if (type == \"video\") {\n" +
                    "                        $(obj).parent().append(\"\" +\n" +
                    "                            \"<video class=\\\"class-video class-show-upload-frame class-show-upload-frame-\" + id + \"\\\" preload=\\\"none\\\" muted=\\\"muted\\\" controls=\\\"controls\\\" src=\\\"\" + res.data.fileFullUrl + \"\\\" height=\\\"300px;\\\"></video>\"\n" +
                    "                        );\n" +
                    "                    } else if (type == \"image\") {\n" +
                    "                        $(obj).parent().append(\"\" +\n" +
                    "                            \"<image class=\\\"class-image class-show-upload-frame class-show-upload-frame-\" + id + \"\\\" src=\\\"\" + res.data.fileFullUrl + \"\\\" height=\\\"300px;\\\"></image>\"\n" +
                    "                        );\n" +
                    "                    } else if (type == \"file\") {\n" +
                    "                        $(obj).parent().append(\"\" +\n" +
                    "                            \"<a class=\\\"class-a class-show-upload-frame class-show-upload-frame-\" + id + \"\\\" href=\\\"\" + res.data.fileFullUrl + \"\\\" >\" + name + \"</a>\"\n" +
                    "                        );\n" +
                    "                    }\n" +
                    "                } else {\n" +
                    "                    checkError(res);\n" +
                    "                }\n" +
                    "            },\n" +
                    "            error: function (message) {\n" +
                    "                showAlertFrame(ERROR_MESSAGE_CANNOT_CONNECT_TO_SERVER);\n" +
                    "            }\n" +
                    "        });\n" +
                    "    })\n" +
                    "}\n" +
                    "\n" +
                    "var closeUploadFrame = function (id) {\n" +
                    "    $(\".class-div-upload-frame-\" + id).fadeOut(300, function () {\n" +
                    "        $(\".class-div-upload-frame-\" + id).remove();\n" +
                    "    });\n" +
                    "}\n" +
                    "\n" +
                    "var getUrlSplit = function (splitUrl) {\n" +
                    "    var ids = location.href.split(splitUrl);\n" +
                    "    var id = \"\";\n" +
                    "    if (ids.length > 1) {\n" +
                    "        var id1 = ids[1].split(\"&\");\n" +
                    "        id = id1[0];\n" +
                    "    }\n" +
                    "    return id.split('#')[0];\n" +
                    "}\n" +
                    "\n" +
                    "var logoutOnly = function () {\n" +
                    "    localStorage.clear();\n" +
                    "}\n" +
                    "\n" +
                    "var showPictureClickFuntion = function () {\n" +
                    "    if ($(\"image\").length == 0 && $(\"img\").length == 0) {\n" +
                    "    } else {\n" +
                    "        for (var i = 0; i < $(\"image\").length; i++) {\n" +
                    "            if ($($(\"image\")[i]).attr(\"hasBindClick\") == undefined) {\n" +
                    "                if ($($(\"image\")[i]).attr(\"unbind\") == undefined) {\n" +
                    "                    $($(\"image\")[i]).bind(\"click\", function (event) {\n" +
                    "                        showPictureFrame(this);\n" +
                    "                    });\n" +
                    "                }\n" +
                    "                $($(\"image\")[i]).attr(\"hasBindClick\", \"1\");\n" +
                    "            }\n" +
                    "        }\n" +
                    "        for (var i = 0; i < $(\"img\").length; i++) {\n" +
                    "            if ($($(\"img\")[i]).attr(\"hasBindClick\") == undefined) {\n" +
                    "                if ($($(\"img\")[i]).attr(\"unbind\") == undefined) {\n" +
                    "                    $($(\"img\")[i]).bind(\"click\", function (event) {\n" +
                    "                        showPictureFrame(this);\n" +
                    "                    });\n" +
                    "                }\n" +
                    "                $($(\"img\")[i]).attr(\"hasBindClick\", \"1\");\n" +
                    "            }\n" +
                    "        }\n" +
                    "    }\n" +
                    "    setTimeout(showPictureClickFuntion, 1666);\n" +
                    "}\n" +
                    "\n" +
                    "var showPictureFrame = function (obj) {\n" +
                    "    $(\"body\").append(\"<div onclick='closePictureFrame()' style='z-index: 9999;position: absolute;top:0;left:0;width:100%;height:100%;' class='class-div-picture-frame'>\" +\n" +
                    "        \"<div class='class-div-picture-frame-image-container' onclick='closePictureFrame()' \" +\n" +
                    "        \"style='border-radius:26px;margin:26px;\" +\n" +
                    "        \"background-image: linear-gradient(to top,#EEEEEE,#FFFFFF);border:1px solid #666666;\" +\n" +
                    "        \"width:95%;padding:26px;color:black;overflow:hidden;'>\" +\n" +
                    "        \"<div class='class-div-picture-frame-image'  style='text-align:center;'><span class='class-span-picture-frame-image' ><image class='class-image-picture-frame-image'  src='\" + $(obj).attr(\"src\") + \"'/></span></div>\" +\n" +
                    "        \"</div>\" +\n" +
                    "        \"</div>\");\n" +
                    "    $(\"html,body\").animate({\n" +
                    "        scrollTop: 0\n" +
                    "    }, 0);\n" +
                    "}\n" +
                    "\n" +
                    "var closePictureFrame = function (obj) {\n" +
                    "    $('.class-div-picture-frame').remove();\n" +
                    "}\n" +
                    "\n" +
                    "var getRandomId = function () {\n" +
                    "    var randomId = new Date().getTime();\n" +
                    "    randomId = \"\" + randomId;\n" +
                    "    randomId = randomId.replace(/4/g, \"6\");\n" +
                    "    for (var i = 0; i < 23; i++) {\n" +
                    "        var number = Math.floor(Math.random() * 10);\n" +
                    "        number = number == 4 ? 6 : number;\n" +
                    "        randomId += number + \"\";\n" +
                    "    }\n" +
                    "    return randomId;\n" +
                    "}\n" +
                    "\n" +
                    "var getCurrentTime = function () {\n" +
                    "    var date = new Date();\n" +
                    "    var Y = date.getFullYear() + '-';\n" +
                    "    var M = (date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1) : date.getMonth() + 1) + '-';\n" +
                    "    var D = (date.getDate() < 10 ? '0' + (date.getDate()) : date.getDate()) + ' ';\n" +
                    "    var h = (date.getHours() < 10 ? '0' + (date.getHours()) : date.getHours()) + ':';\n" +
                    "    var m = (date.getMinutes() < 10 ? '0' + (date.getMinutes()) : date.getMinutes()) + ':';\n" +
                    "    var s = (date.getSeconds() < 10 ? '0' + (date.getSeconds()) : date.getSeconds());\n" +
                    "    return Y + M + D + h + m + s;\n" +
                    "}\n" +
                    "\n" +
                    "var getCurrentWithT = function () {\n" +
                    "    var date = new Date();\n" +
                    "    var Y = date.getFullYear() + '-';\n" +
                    "    var M = (date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1) : date.getMonth() + 1) + '-';\n" +
                    "    var D = (date.getDate() < 10 ? '0' + (date.getDate()) : date.getDate()) + 'T';\n" +
                    "    var h = (date.getHours() < 10 ? '0' + (date.getHours()) : date.getHours()) + ':';\n" +
                    "    var m = (date.getMinutes() < 10 ? '0' + (date.getMinutes()) : date.getMinutes()) + ':';\n" +
                    "    var s = (date.getSeconds() < 10 ? '0' + (date.getSeconds()) : date.getSeconds());\n" +
                    "    return Y + M + D + h + m + s;\n" +
                    "}\n" +
                    "\n" +
                    "var getCurrentDate = function () {\n" +
                    "    var date = new Date();\n" +
                    "    var Y = date.getFullYear() + '/';\n" +
                    "    var M = (date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1) : date.getMonth() + 1) + '/';\n" +
                    "    var D = (date.getDate() < 10 ? '0' + (date.getDate()) : date.getDate()) + '';\n" +
                    "    return Y + M + D;\n" +
                    "}\n" +
                    "\n" +
                    "var timestampToTime = function (timestamp) {\n" +
                    "    var date = new Date(timestamp);\n" +
                    "    var Y = date.getFullYear() + '-';\n" +
                    "    var M = (date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1) : date.getMonth() + 1) + '-';\n" +
                    "    var D = (date.getDate() < 10 ? '0' + (date.getDate()) : date.getDate()) + ' ';\n" +
                    "    var h = (date.getHours() < 10 ? '0' + (date.getHours()) : date.getHours()) + ':';\n" +
                    "    var m = (date.getMinutes() < 10 ? '0' + (date.getMinutes()) : date.getMinutes()) + ':';\n" +
                    "    var s = (date.getSeconds() < 10 ? '0' + (date.getSeconds()) : date.getSeconds());\n" +
                    "    return Y + M + D + h + m + s;\n" +
                    "}\n" +
                    "\n" +
                    "var timestampToTimeWithT = function (timestamp) {\n" +
                    "    var date = new Date(timestamp);\n" +
                    "    var Y = date.getFullYear() + '-';\n" +
                    "    var M = (date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1) : date.getMonth() + 1) + '-';\n" +
                    "    var D = (date.getDate() < 10 ? '0' + (date.getDate()) : date.getDate()) + 'T';\n" +
                    "    var h = (date.getHours() < 10 ? '0' + (date.getHours()) : date.getHours()) + ':';\n" +
                    "    var m = (date.getMinutes() < 10 ? '0' + (date.getMinutes()) : date.getMinutes()) + ':';\n" +
                    "    var s = (date.getSeconds() < 10 ? '0' + (date.getSeconds()) : date.getSeconds());\n" +
                    "    return Y + M + D + h + m + s;\n" +
                    "}\n" +
                    "\n" +
                    "var timestampToDate = function (timestamp) {\n" +
                    "    var date = new Date(timestamp);\n" +
                    "    var Y = date.getFullYear() + '/';\n" +
                    "    var M = (date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1) : date.getMonth() + 1) + '/';\n" +
                    "    var D = (date.getDate() < 10 ? '0' + (date.getDate()) : date.getDate()) + '';\n" +
                    "    return Y + M + D;\n" +
                    "}\n" +
                    "\n" +
                    "var showDatePicker = function (className) {\n" +
                    "    $(className).datepicker({\n" +
                    "        changeMonth: true,\n" +
                    "        changeYear: true,\n" +
                    "        buttonImageOnly: true,\n" +
                    "        minDate: '-100y', maxDate: '+30y',\n" +
                    "        dateFormat: 'yy-mm-dd',\n" +
                    "        showButtonPanel: true,\n" +
                    "        showOtherMonths: true,\n" +
                    "        selectOtherMonths: true,\n" +
                    "        showMonthAfterYear: true,\n" +
                    "        yearRange: \"1956:2199\"\n" +
                    "    });\n" +
                    "}\n" +
                    "\n" +
                    "var setSelect = function (className, text) {\n" +
                    "    var count = $(className + \" option\").length;\n" +
                    "    for (var i = 0; i < count; i++) {\n" +
                    "        if ($(className).get(0).options[i].text == text) {\n" +
                    "            $(className).get(0).options[i].selected = true;\n" +
                    "            break;\n" +
                    "        }\n" +
                    "    }\n" +
                    "}\n" +
                    "\n" +
                    "\n" +
                    "var getPager = function (res, url) {\n" +
                    "    if (res.data == null) {\n" +
                    "        return \"\";\n" +
                    "    }\n" +
                    "    var page = res.page;\n" +
                    "    var totalPage = res.totalPage;\n" +
                    "    var pagerHtml = \"<div class='class-div-page-pager'>\";\n" +
                    "    pagerHtml += \"<span class='class-span-page-pager' onclick=\\\"getMainProcess('\" + getNavigatorUrl(1, url) + \"')\\\">首页</a></span>\";\n" +
                    "    if (page > 1) {\n" +
                    "        pagerHtml += \"<span class='class-span-page-pager' onclick=\\\"getMainProcess('\" + getNavigatorUrl(1, url) + \"')\\\">1</a></span>\";\n" +
                    "    }\n" +
                    "    if (page > 7) {\n" +
                    "        pagerHtml += \"<span class='class-span-page-pager' onclick=\\\"getMainProcess('\" + getNavigatorUrl(page - 6, url) + \"')\\\">\" + (page - 6) + \"</a></span>\";\n" +
                    "    }\n" +
                    "    if (page > 6) {\n" +
                    "        pagerHtml += \"<span class='class-span-page-pager' onclick=\\\"getMainProcess('\" + getNavigatorUrl(page - 5, url) + \"')\\\">\" + (page - 5) + \"</a></span>\";\n" +
                    "    }\n" +
                    "    if (page > 5) {\n" +
                    "        pagerHtml += \"<span class='class-span-page-pager' onclick=\\\"getMainProcess('\" + getNavigatorUrl(page - 4, url) + \"')\\\">\" + (page - 4) + \"</a></span>\";\n" +
                    "    }\n" +
                    "    if (page > 4) {\n" +
                    "        pagerHtml += \"<span class='class-span-page-pager' onclick=\\\"getMainProcess('\" + getNavigatorUrl(page - 3, url) + \"')\\\">\" + (page - 3) + \"</a></span>\";\n" +
                    "    }\n" +
                    "    if (page > 3) {\n" +
                    "        pagerHtml += \"<span class='class-span-page-pager' onclick=\\\"getMainProcess('\" + getNavigatorUrl(page - 2, url) + \"')\\\">\" + (page - 2) + \"</a></span>\";\n" +
                    "    }\n" +
                    "    if (page > 2) {\n" +
                    "        pagerHtml += \"<span class='class-span-page-pager' onclick=\\\"getMainProcess('\" + getNavigatorUrl(page - 1, url) + \"')\\\">\" + (page - 1) + \"</a></span>\";\n" +
                    "    }\n" +
                    "\n" +
                    "    pagerHtml += \"<span class='class-span-page-pager class-span-page-pager-selected' onclick=\\\"getMainProcess('\" + getNavigatorUrl(page, url) + \"')\\\">\" + (page) + \"</a></span>\";\n" +
                    "\n" +
                    "    if (page < totalPage - 1) {\n" +
                    "        pagerHtml += \"<span class='class-span-page-pager' onclick=\\\"getMainProcess('\" + getNavigatorUrl(page + 1, url) + \"')\\\">\" + (page + 1) + \"</a></span>\";\n" +
                    "    }\n" +
                    "    if (page < totalPage - 2) {\n" +
                    "        pagerHtml += \"<span class='class-span-page-pager' onclick=\\\"getMainProcess('\" + getNavigatorUrl(page + 2, url) + \"')\\\">\" + (page + 2) + \"</a></span>\";\n" +
                    "    }\n" +
                    "    if (page < totalPage - 3) {\n" +
                    "        pagerHtml += \"<span class='class-span-page-pager' onclick=\\\"getMainProcess('\" + getNavigatorUrl(page + 3, url) + \"')\\\">\" + (page + 3) + \"</a></span>\";\n" +
                    "    }\n" +
                    "\n" +
                    "    if (page < totalPage - 4) {\n" +
                    "        pagerHtml += \"<span class='class-span-page-pager' onclick=\\\"getMainProcess('\" + getNavigatorUrl(page + 4, url) + \"')\\\">\" + (page + 4) + \"</a></span>\";\n" +
                    "    }\n" +
                    "    if (page < totalPage - 5) {\n" +
                    "        pagerHtml += \"<span class='class-span-page-pager' onclick=\\\"getMainProcess('\" + getNavigatorUrl(page + 5, url) + \"')\\\">\" + (page + 5) + \"</a></span>\";\n" +
                    "    }\n" +
                    "    if (page < totalPage - 6) {\n" +
                    "        pagerHtml += \"<span class='class-span-page-pager' onclick=\\\"getMainProcess('\" + getNavigatorUrl(page + 6, url) + \"')\\\">\" + (page + 6) + \"</a></span>\";\n" +
                    "    }\n" +
                    "    if (page < totalPage - 7) {\n" +
                    "        pagerHtml += \"<span class='class-span-page-pager' onclick=\\\"getMainProcess('\" + getNavigatorUrl(page + 7, url) + \"')\\\">\" + (page + 7) + \"</a></span>\";\n" +
                    "    }\n" +
                    "\n" +
                    "    if (page < totalPage) {\n" +
                    "        pagerHtml += \"<span class='class-span-page-pager' onclick=\\\"getMainProcess('\" + getNavigatorUrl(totalPage, url) + \"')\\\">\" + (totalPage) + \"</a></span>\";\n" +
                    "    }\n" +
                    "    pagerHtml += \"<span class='class-span-page-pager' onclick=\\\"getMainProcess('\" + getNavigatorUrl(page + 1, url) + \"')\\\">\" + \"下一页\" + \"</a></span>\";\n" +
//                    "    pagerHtml += \"<span><input type='text' value='' placeholder='页码' class='class-input-jump-page' /></span>" +
//                    "<button class='class-button-jump-page iconfont' onclick=\\\"gotoPage('\" + url + \"')\\\"></button>\";\n" +
                    "    pagerHtml += \"</div>\";\n" +
                    "    return pagerHtml;\n" +
                    "}\n" +
                    "\n" +
                    "var getNavigatorUrl = function (page, url) {\n" +
                    "    var url0 = url.split(\"#\");\n" +
                    "    var urls1 = url0[0].split(\"page=\");\n" +
                    "    if (urls1.length > 1) {\n" +
                    "        var urls2 = urls1[1].split(\"&\");\n" +
                    "        if (urls2.length > 1) {\n" +
                    "            var urls3 = \"\";\n" +
                    "            for (var i = 1; i < urls2.length; i++) {\n" +
                    "                urls3 += \"&\" + urls2[i]\n" +
                    "            }\n" +
                    "            return urls1[0] + \"page=\" + page + urls3;\n" +
                    "        } else {\n" +
                    "            return urls1[0] + \"page=\" + page;\n" +
                    "        }\n" +
                    "    } else {\n" +
                    "        urls1 = url.split(\"?\");\n" +
                    "        if (urls1.length > 1) {\n" +
                    "            return url0[0] + \"&page=\" + page + (url0.length > 1 ? \"#\" + url0[1] : \"\");\n" +
                    "        } else {\n" +
                    "            return url0[0] + \"?page=\" + page + (url0.length > 1 ? \"#\" + url0[1] : \"\");\n" +
                    "        }\n" +
                    "    }\n" +
                    "}\n" +
                    "\n" +
//                    "var gotoPage = function (url) {\n" +
//                    "    getMainProcess(getNavigatorUrl($(\".class-input-jump-page\").val(), url));\n" +
//                    "}\n" +
                    "\n" +
                    "\n" +
                    "var getPagerWithClassNameAndSingleOrList = function (res, url, className, singleOrList, tableOriginalName, tableDomainObjectName, tableRemarks) {\n" +
                    "    if (res.data == null) {\n" +
                    "        return \"\";\n" +
                    "    }\n" +
                    "    var page = res.page;\n" +
                    "    var totalPage = res.totalPage;\n" +
                    "    var pagerHtml = \"<div class='class-div-page-pager'>\";\n" +
                    "    if(totalPage==1){\n" +
                    "        return pagerHtml+'</div>';\n" +
                    "    }\n" +
                    "    if (page > 1) {\n" +
                    "        pagerHtml += \"<span class='class-span-page-pager' onclick=\\\"getMainProcessWithClassNameAndList('\" + getNavigatorUrl(1, url) + \"','\" + className + \"','\" + singleOrList + \"','\" + tableOriginalName + \"','\" + tableDomainObjectName + \"','\" + tableRemarks + \"')\\\">1</a></span>\";\n" +
                    "    }\n" +
                    "    if (page > 7) {\n" +
                    "        pagerHtml += \"<span class='class-span-page-pager' onclick=\\\"getMainProcessWithClassNameAndList('\" + getNavigatorUrl(page - 6, url) + \"','\" + className + \"','\" + singleOrList + \"','\" + tableOriginalName + \"','\" + tableDomainObjectName + \"','\" + tableRemarks + \"')\\\">\" + (page - 6) + \"</a></span>\";\n" +
                    "    }\n" +
                    "    if (page > 6) {\n" +
                    "        pagerHtml += \"<span class='class-span-page-pager' onclick=\\\"getMainProcessWithClassNameAndList('\" + getNavigatorUrl(page - 5, url) + \"','\" + className + \"','\" + singleOrList + \"','\" + tableOriginalName + \"','\" + tableDomainObjectName + \"','\" + tableRemarks + \"')\\\">\" + (page - 5) + \"</a></span>\";\n" +
                    "    }\n" +
                    "    if (page > 5) {\n" +
                    "        pagerHtml += \"<span class='class-span-page-pager' onclick=\\\"getMainProcessWithClassNameAndList('\" + getNavigatorUrl(page - 4, url) + \"','\" + className + \"','\" + singleOrList + \"','\" + tableOriginalName + \"','\" + tableDomainObjectName + \"','\" + tableRemarks + \"')\\\">\" + (page - 4) + \"</a></span>\";\n" +
                    "    }\n" +
                    "    if (page > 4) {\n" +
                    "        pagerHtml += \"<span class='class-span-page-pager' onclick=\\\"getMainProcessWithClassNameAndList('\" + getNavigatorUrl(page - 3, url) + \"','\" + className + \"','\" + singleOrList + \"','\" + tableOriginalName + \"','\" + tableDomainObjectName + \"','\" + tableRemarks + \"')\\\">\" + (page - 3) + \"</a></span>\";\n" +
                    "    }\n" +
                    "    if (page > 3) {\n" +
                    "        pagerHtml += \"<span class='class-span-page-pager' onclick=\\\"getMainProcessWithClassNameAndList('\" + getNavigatorUrl(page - 2, url) + \"','\" + className + \"','\" + singleOrList + \"','\" + tableOriginalName + \"','\" + tableDomainObjectName + \"','\" + tableRemarks + \"')\\\">\" + (page - 2) + \"</a></span>\";\n" +
                    "    }\n" +
                    "    if (page > 2) {\n" +
                    "        pagerHtml += \"<span class='class-span-page-pager' onclick=\\\"getMainProcessWithClassNameAndList('\" + getNavigatorUrl(page - 1, url) + \"','\" + className + \"','\" + singleOrList + \"','\" + tableOriginalName + \"','\" + tableDomainObjectName + \"','\" + tableRemarks + \"')\\\">\" + (page - 1) + \"</a></span>\";\n" +
                    "    }\n" +
                    "\n" +
                    "    pagerHtml += \"<span class='class-span-page-pager class-span-page-pager-selected' onclick=\\\"getMainProcessWithClassNameAndList('\" + getNavigatorUrl(page, url) + \"','\" + className + \"','\" + singleOrList + \"','\" + tableOriginalName + \"','\" + tableDomainObjectName + \"','\" + tableRemarks + \"')\\\">\" + (page) + \"</a></span>\";\n" +
                    "\n" +
                    "    if (page < totalPage - 1) {\n" +
                    "        pagerHtml += \"<span class='class-span-page-pager' onclick=\\\"getMainProcessWithClassNameAndList('\" + getNavigatorUrl(page + 1, url) + \"','\" + className + \"','\" + singleOrList + \"','\" + tableOriginalName + \"','\" + tableDomainObjectName + \"','\" + tableRemarks + \"')\\\">\" + (page + 1) + \"</a></span>\";\n" +
                    "    }\n" +
                    "    if (page < totalPage - 2) {\n" +
                    "        pagerHtml += \"<span class='class-span-page-pager' onclick=\\\"getMainProcessWithClassNameAndList('\" + getNavigatorUrl(page + 2, url) + \"','\" + className + \"','\" + singleOrList + \"','\" + tableOriginalName + \"','\" + tableDomainObjectName + \"','\" + tableRemarks + \"')\\\">\" + (page + 2) + \"</a></span>\";\n" +
                    "    }\n" +
                    "    if (page < totalPage - 3) {\n" +
                    "        pagerHtml += \"<span class='class-span-page-pager' onclick=\\\"getMainProcessWithClassNameAndList('\" + getNavigatorUrl(page + 3, url) + \"','\" + className + \"','\" + singleOrList + \"','\" + tableOriginalName + \"','\" + tableDomainObjectName + \"','\" + tableRemarks + \"')\\\">\" + (page + 3) + \"</a></span>\";\n" +
                    "    }\n" +
                    "\n" +
                    "    if (page < totalPage - 4) {\n" +
                    "        pagerHtml += \"<span class='class-span-page-pager' onclick=\\\"getMainProcessWithClassNameAndList('\" + getNavigatorUrl(page + 4, url) + \"','\" + className + \"','\" + singleOrList + \"','\" + tableOriginalName + \"','\" + tableDomainObjectName + \"','\" + tableRemarks + \"')\\\">\" + (page + 4) + \"</a></span>\";\n" +
                    "    }\n" +
                    "    if (page < totalPage - 5) {\n" +
                    "        pagerHtml += \"<span class='class-span-page-pager' onclick=\\\"getMainProcessWithClassNameAndList('\" + getNavigatorUrl(page + 5, url) + \"','\" + className + \"','\" + singleOrList + \"','\" + tableOriginalName + \"','\" + tableDomainObjectName + \"','\" + tableRemarks + \"')\\\">\" + (page + 5) + \"</a></span>\";\n" +
                    "    }\n" +
                    "    if (page < totalPage - 6) {\n" +
                    "        pagerHtml += \"<span class='class-span-page-pager' onclick=\\\"getMainProcessWithClassNameAndList('\" + getNavigatorUrl(page + 6, url) + \"','\" + className + \"','\" + singleOrList + \"','\" + tableOriginalName + \"','\" + tableDomainObjectName + \"','\" + tableRemarks + \"')\\\">\" + (page + 6) + \"</a></span>\";\n" +
                    "    }\n" +
                    "    if (page < totalPage - 7) {\n" +
                    "        pagerHtml += \"<span class='class-span-page-pager' onclick=\\\"getMainProcessWithClassNameAndList('\" + getNavigatorUrl(page + 7, url) + \"','\" + className + \"','\" + singleOrList + \"','\" + tableOriginalName + \"','\" + tableDomainObjectName + \"','\" + tableRemarks + \"')\\\">\" + (page + 7) + \"</a></span>\";\n" +
                    "    }\n" +
                    "\n" +
                    "    if (page < totalPage) {\n" +
                    "        pagerHtml += \"<span class='class-span-page-pager' onclick=\\\"getMainProcessWithClassNameAndList('\" + getNavigatorUrl(totalPage, url) + \"','\" + className + \"','\" + singleOrList + \"','\" + tableOriginalName + \"','\" + tableDomainObjectName + \"','\" + tableRemarks + \"')\\\">\" + (totalPage) + \"</a></span>\";\n" +
                    "    }\n" +
                    "    if(totalPage>15){\n" +
                    "        pagerHtml += \"<span class='class-span-page-pager' onclick=\\\"getMainProcessWithClassNameAndList('\" + getNavigatorUrl(page + 1, url) + \"','\" + className + \"','\" + singleOrList + \"','\" + tableOriginalName + \"','\" + tableDomainObjectName + \"','\" + tableRemarks + \"')\\\">\" + \"下一页\" + \"</a></span>\";\n" +
//                    "        pagerHtml += \"<span><input type='text' value='' placeholder='页码' class='class-input-jump-page' /></span>" +
//                    "<button class='class-button-jump-page iconfont' onclick=\\\"gotoPageWithClassNameAndSingleOrList('\" + url + \"','\" + className + \"','\" + singleOrList + \"','\" + tableOriginalName + \"','\" + tableDomainObjectName + \"','\" + tableRemarks + \"')\\\"></button>\";\n" +
                    "    }\n" +
                    "    pagerHtml += \"</div>\";\n" +
                    "    return pagerHtml;\n" +
                    "}\n" +
                    "\n" +
//                    "var gotoPageWithClassNameAndSingleOrList = function (url, className, singleOrList, tableOriginalName, tableDomainObjectName, tableRemarks) {\n" +
//                    "    getMainProcessWithClassNameAndList(getNavigatorUrl($(\".class-input-jump-page\").val(), url), className, singleOrList, tableOriginalName, tableDomainObjectName, tableRemarks);\n" +
//                    "}\n" +
                    "\n" +
                    "var toLowercaseAtFirstCharacter = function (string) {\n" +
                    "    return string.substring(0,1).toLocaleLowerCase()+string.substring(1);\n" +
                    "}\n" +
                    "\n");
            System.out.println("write to file success : " + file.getPath());
        } catch (IOException e) {
            e.printStackTrace();
        } finally {
            MybatisUtilCommon.closeBufferWriterAndFileOutputStream(fileOutputStream, bufferedWriter);
        }
    }

    public static void writeCommonPageShareJsCommonProvinceCityJs(String htmlPath, String serverUrl) {
        File file = null;
        OutputStream fileOutputStream = null;
        BufferedWriter bufferedWriter = null;
        try {
            File folder = new File(htmlPath + "/common/page-share/js");
            folder.mkdirs();
            file = new File(htmlPath + "/common/page-share/js/common-province-city.js");
            //如果文件不存在，则创建文件，如果已存在，则覆盖
            file.createNewFile();
            fileOutputStream = new FileOutputStream(file);
            bufferedWriter = new BufferedWriter(new OutputStreamWriter(fileOutputStream, "utf-8"));
            bufferedWriter.write("var province = [{ name: \"北京市\", city: [{ name: \"北京市\", districtAndCounty: [\"东城区\", \"西城区\", \"崇文区\", \"宣武区\", \"朝阳区\", \"丰台区\", \"石景山区\", \"海淀区\", \"门头沟区\", \"房山区\", \"通州区\", \"顺义区\", \"昌平区\", \"大兴区\", \"怀柔区\", \"平谷区\", \"密云县\", \"延庆县\", \"延庆镇\"] }]}, { name: \"天津市\", city: [{ name: \"天津市\", districtAndCounty: [\"和平区\", \"河东区\", \"河西区\", \"南开区\", \"河北区\", \"红桥区\", \"塘沽区\", \"汉沽区\", \"大港区\", \"东丽区\", \"西青区\", \"津南区\", \"北辰区\", \"武清区\", \"宝坻区\", \"蓟县\", \"宁河县\", \"芦台镇\", \"静海县\", \"静海镇\"] }]}, { name: \"上海市\", city: [{ name: \"上海市\", districtAndCounty: [\"黄浦区\", \"卢湾区\", \"徐汇区\", \"长宁区\", \"静安区\", \"普陀区\", \"闸北区\", \"虹口区\", \"杨浦区\", \"闵行区\", \"宝山区\", \"嘉定区\", \"浦东新区\", \"金山区\", \"松江区\", \"青浦区\", \"南汇区\", \"奉贤区\", \"崇明县\", \"城桥镇\"] }]}, { name: \"重庆市\", city: [{ name: \"重庆市\", districtAndCounty: [\"渝中区\", \"大渡口区\", \"江北区\", \"沙坪坝区\", \"九龙坡区\", \"南岸区\", \"北碚区\", \"万盛区\", \"双桥区\", \"渝北区\", \"巴南区\", \"万州区\", \"涪陵区\", \"黔江区\", \"长寿区\", \"合川市\", \"永川区市\", \"江津市\", \"南川市\", \"綦江县\", \"潼南县\", \"铜梁县\", \"大足县\", \"荣昌县\", \"璧山县\", \"垫江县\", \"武隆县\", \"丰都县\", \"城口县\", \"梁平县\", \"开县\", \"巫溪县\", \"巫山县\", \"奉节县\", \"云阳县\", \"忠县\", \"石柱土家族自治县\", \"彭水苗族土家族自治县\", \"酉阳土家族苗族自治县\", \"秀山土家族苗族自治县\"] }]}, { name: \"河北省\", city: [{ name: \"石家庄市\", districtAndCounty: [\"长安区\", \"桥东区\", \"桥西区\", \"新华区\", \"裕华区\", \"井陉矿区\", \"辛集市\", \"藁城市\", \"晋州市\", \"新乐市\", \"鹿泉市\", \"井陉县\", \"微水镇\", \"正定县\", \"正定镇\", \"栾城县\", \"栾城镇\", \"行唐县\", \"龙州镇\", \"灵寿县\", \"灵寿镇\", \"高邑县\", \"高邑镇\", \"深泽县\", \"深泽镇\", \"赞皇县\", \"赞皇镇\", \"无极县\", \"无极镇\", \"平山县\", \"平山镇\", \"元氏县\", \"槐阳镇\", \"赵县\", \"赵州镇\"] }, { name: \"张家口市\", districtAndCounty: [\"桥西区\", \"桥东区\", \"宣化区\", \"下花园区\", \"宣化县\", \"张家口市宣化区\", \"张北县\", \"张北镇\", \"康保县\", \"康保镇\", \"沽源县\", \"平定堡镇\", \"尚义县\", \"南壕堑镇\", \"蔚县\", \"蔚州镇\", \"阳原县\", \"西城镇\", \"怀安县\", \"柴沟堡镇\", \"万全县\", \"孔家庄镇\", \"怀来县\", \"沙城镇\", \"涿鹿县\", \"涿鹿镇\", \"赤城县\", \"赤城镇\", \"崇礼县\", \"西湾子镇\"] }, { name: \"承德市\", districtAndCounty: [\"双桥区\", \"双滦区\", \"鹰手营子矿区\", \"承德县\", \"下板城镇\", \"兴隆县\", \"兴隆镇\", \"平泉县\", \"平泉镇\", \"滦平县\", \"滦平镇\", \"隆化县\", \"隆化镇\", \"丰宁满族自治县\", \"大阁镇\", \"宽城满族自治县\", \"宽城镇\", \"围场满族蒙古族自治县\", \"围场镇\"] }, { name: \"秦皇岛市\", districtAndCounty: [\"海港区\", \"山海关区\", \"北戴河区\", \"昌黎县\", \"昌黎镇\", \"抚宁县\", \"抚宁镇\", \"卢龙县\", \"卢龙镇\", \"青龙满族自治县\", \"青龙镇\"] }, { name: \"唐山市\", districtAndCounty: [\"路北区\", \"路南区\", \"古冶区\", \"开平区\", \"丰润区\", \"丰南区\", \"遵化市\", \"迁安市\", \"滦县\", \"滦州镇\", \"滦南县\", \"倴城镇\", \"乐亭县\", \"乐亭镇\", \"迁西县\", \"兴城镇\", \"玉田县\", \"玉田镇\", \"唐海县\", \"唐海镇\"] }, { name: \"廊坊市\", districtAndCounty: [\"安次区\", \"广阳区\", \"霸州市\", \"三河市\", \"固安县\", \"固安镇\", \"永清县\", \"永清镇\", \"香河县\", \"淑阳镇\", \"大城县\", \"平舒镇\", \"文安县\", \"文安镇\", \"大厂回族自治县\", \"大厂镇\"] }, { name: \"保定市\", districtAndCounty: [\"新市区\", \"北市区\", \"南市区\", \"定州市\", \"涿州市\", \"安国市\", \"高碑店市\", \"满城县\", \"满城镇\", \"清苑县\", \"清苑镇\", \"易县\", \"易州镇\", \"徐水县\", \"安肃镇\", \"涞源县\", \"涞源镇\", \"定兴县\", \"定兴镇\", \"顺平县\", \"蒲阳镇\", \"唐县\", \"仁厚镇\", \"望都县\", \"望都镇\", \"涞水县\", \"涞水镇\", \"高阳县\", \"高阳镇\", \"安新县\", \"安新镇\", \"雄县\", \"雄州镇\", \"容城县\", \"容城镇\", \"曲阳县\", \"恒州镇\", \"阜平县\", \"阜平镇\", \"博野县\", \"博陵镇\", \"蠡县\", \"蠡吾镇\"] }, { name: \"衡水市\", districtAndCounty: [\"桃城区\", \"冀州市\", \"深州市\", \"枣强县\", \"枣强镇\", \"武邑县\", \"武邑镇\", \"武强县\", \"武强镇\", \"饶阳县\", \"饶阳镇\", \"安平县\", \"安平镇\", \"故城县\", \"郑口镇\", \"景县\", \"景州镇\", \"阜城县\", \"阜城镇\"] }, { name: \"沧州市\", districtAndCounty: [\"运河区\", \"新华区\", \"泊头市\", \"任丘市\", \"黄骅市\", \"河间市\", \"沧县\", \"沧州市新华区\", \"青县\", \"清州镇\", \"东光县\", \"东光镇\", \"海兴县\", \"苏基镇\", \"盐山县\", \"盐山镇\", \"肃宁县\", \"肃宁镇\", \"南皮县\", \"南皮镇\", \"吴桥县\", \"桑园镇\", \"献县\", \"乐寿镇\", \"孟村回族自治县\", \"孟村镇\"] }, { name: \"邢台市\", districtAndCounty: [\"桥东区\", \"桥西区\", \"南宫市\", \"沙河市\", \"邢台县\", \"邢台市桥东区\", \"临城县\", \"临城镇\", \"内丘县\", \"内丘镇\", \"柏乡县\", \"柏乡镇\", \"隆尧县\", \"隆尧镇\", \"任县\", \"任城镇\", \"南和县\", \"和阳镇\", \"宁晋县\", \"凤凰镇\", \"巨鹿县\", \"巨鹿镇\", \"新河县\", \"新河镇\", \"广宗县\", \"广宗镇\", \"平乡县\", \"丰州镇\", \"威县\", \"洺州镇\", \"清河县\", \"葛仙庄镇\", \"临西县\", \"临西镇\"] }, { name: \"邯郸市\", districtAndCounty: [\"丛台区\", \"邯山区\", \"复兴区\", \"峰峰矿区\", \"武安市\", \"邯郸县\", \"南堡乡东小屯村\", \"临漳县\", \"临漳镇\", \"成安县\", \"成安镇\", \"大名县\", \"大名镇\", \"涉县\", \"涉城镇\", \"磁县\", \"磁州镇\", \"肥乡县\", \"肥乡镇\", \"永年县\", \"临洺关镇\", \"邱县\", \"新马头镇\", \"鸡泽县\", \"鸡泽镇\", \"广平县\", \"广平镇\", \"馆陶县\", \"馆陶镇\", \"魏县\", \"魏城镇\", \"曲周县\", \"曲周镇\"] }]}, { name: \"山西省\", city: [{ name: \"太原市\", districtAndCounty: [\"杏花岭区\", \"小店区\", \"迎泽区\", \"尖草坪区\", \"万柏林区\", \"晋源区\", \"古交市\", \"清徐县\", \"清源镇\", \"阳曲县\", \"黄寨镇\", \"娄烦县\", \"娄烦镇\"] }, { name: \"朔州市\", districtAndCounty: [\"朔城区\", \"平鲁区\", \"山阴县\", \"岱岳乡\", \"应县\", \"金城镇\", \"右玉县\", \"新城镇\", \"怀仁县\", \"云中镇\"] }, { name: \"大同市\", districtAndCounty: [\"城区\", \"矿区\", \"南郊区\", \"新荣区\", \"阳高县\", \"龙泉镇\", \"天镇县\", \"玉泉镇\", \"广灵县\", \"壶泉镇\", \"灵丘县\", \"武灵镇\", \"浑源县\", \"永安镇\", \"左云县\", \"云兴镇\", \"大同县\", \"西坪镇\"] }, {name: \"阳泉市\", districtAndCounty: [\"城区\", \"矿区\", \"郊区\", \"平定县\", \"冠山镇\", \"盂县\", \"秀水镇\"]}, { name: \"长治市\", districtAndCounty: [\"城区\", \"郊区\", \"潞城市\", \"长治县\", \"韩店镇\", \"襄垣县\", \"古韩镇\", \"屯留县\", \"麟绛镇\", \"平顺县\", \"青羊镇\", \"黎城县\", \"黎侯镇\", \"壶关县\", \"龙泉镇\", \"长子县\", \"丹朱镇\", \"武乡县\", \"丰州镇\", \"沁县\", \"定昌镇\", \"沁源县\", \"沁河镇\"] }, { name: \"晋城市\", districtAndCounty: [\"城区\", \"高平市\", \"泽州县\", \"南村镇\", \"沁水县\", \"龙港镇\", \"阳城县\", \"凤城镇\", \"陵川县\", \"崇文镇\"] }, { name: \"忻州市\", districtAndCounty: [\"忻府区\", \"原平市\", \"定襄县\", \"晋昌镇\", \"五台县\", \"台城镇\", \"代县\", \"上馆镇\", \"繁峙县\", \"繁城镇\", \"宁武县\", \"凤凰镇\", \"静乐县\", \"鹅城镇\", \"神池县\", \"龙泉镇\", \"五寨县\", \"砚城镇\", \"岢岚县\", \"岚漪镇\", \"河曲县\", \"文笔镇\", \"保德县\", \"东关镇\", \"偏关县\", \"新关镇\"] }, { name: \"晋中市\", districtAndCounty: [\"榆次区\", \"介休市\", \"榆社县\", \"箕城镇\", \"左权县\", \"辽阳镇\", \"和顺县\", \"义兴镇\", \"昔阳县\", \"乐平镇\", \"寿阳县\", \"朝阳镇\", \"太谷县\", \"明星镇\", \"祁县\", \"昭余镇\", \"平遥县\", \"古陶镇\", \"灵石县\", \"翠峰镇\"] }, { name: \"临汾市\", districtAndCounty: [\"尧都区\", \"侯马市\", \"霍州市\", \"曲沃县\", \"乐昌镇\", \"翼城县\", \"唐兴镇\", \"襄汾县\", \"新城镇\", \"洪洞县\", \"大槐树镇\", \"古县\", \"岳阳镇\", \"安泽县\", \"府城镇\", \"浮山县\", \"天坛镇\", \"吉县\", \"吉昌镇\", \"乡宁县\", \"昌宁镇\", \"蒲县\", \"蒲城镇\", \"大宁县\", \"昕水镇\", \"永和县\", \"芝河镇\", \"隰县\", \"龙泉镇\", \"汾西县\", \"永安镇\"] }, { name: \"吕梁市\", districtAndCounty: [\"离石区\", \"孝义市\", \"汾阳市\", \"文水县\", \"凤城镇\", \"中阳县\", \"宁乡镇\", \"兴县\", \"蔚汾镇\", \"临县\", \"临泉镇\", \"方山县\", \"圪洞镇\", \"柳林县\", \"柳林镇\", \"岚县\", \"东村镇\", \"交口县\", \"水头镇\", \"交城县\", \"天宁镇\", \"石楼县\", \"灵泉镇\"] }, { name: \"运城市\", districtAndCounty: [\"盐湖区\", \"永济市\", \"河津市\", \"芮城县\", \"古魏镇\", \"临猗县\", \"猗氏镇\", \"万荣县\", \"解店镇\", \"新绛县\", \"龙兴镇\", \"稷山县\", \"稷峰镇\", \"闻喜县\", \"桐城镇\", \"夏县\", \"瑶峰镇\", \"绛县\", \"古绛镇\", \"平陆县\", \"圣人涧镇\", \"垣曲县\", \"新城镇\"] }]}, { name: \"内蒙古\", city: [{ name: \"呼和浩特市\", districtAndCounty: [\"回民区\", \"新城区\", \"玉泉区\", \"赛罕区\", \"托克托县\", \"双河镇\", \"武川县\", \"可可以力更镇\", \"和林格尔县\", \"城关镇\", \"清水河县\", \"城关镇\", \"土默特左旗\", \"察素齐镇\"] }, { name: \"包头市\", districtAndCounty: [\"昆都仑区\", \"东河区\", \"青山区\", \"石拐区\", \"白云矿区\", \"九原区\", \"固阳县\", \"金山镇\", \"土默特右旗\", \"萨拉齐镇\", \"达尔罕茂明安联合旗\", \"百灵庙镇\"] }, {name: \"乌海市\", districtAndCounty: [\"海勃湾区\", \"海南区\", \"乌达区\"]}, { name: \"赤峰市\", districtAndCounty: [\"红山区\", \"元宝山区\", \"松山区\", \"宁城县\", \"天义镇\", \"林西县\", \"林西镇\", \"阿鲁科尔沁旗\", \"天山镇\", \"巴林左旗\", \"林东镇\", \"巴林右旗\", \"大板镇\", \"克什克腾旗\", \"经棚镇\", \"翁牛特旗\", \"乌丹镇\", \"喀喇沁旗\", \"锦山镇\", \"敖汉旗\", \"新惠镇\"] }, { name: \"通辽市\", districtAndCounty: [\"科尔沁区\", \"霍林郭勒市\", \"开鲁县\", \"开鲁镇\", \"库伦旗\", \"库伦镇\", \"奈曼旗\", \"大沁他拉镇\", \"扎鲁特旗\", \"鲁北镇\", \"科尔沁左翼中旗\", \"保康镇\", \"科尔沁左翼后旗\", \"甘旗卡镇\"] }, { name: \"呼伦贝尔市\", districtAndCounty: [\"海拉尔区\", \"满洲里市\", \"扎兰屯市\", \"牙克石市\", \"根河市\", \"额尔古纳市\", \"阿荣旗\", \"那吉镇\", \"新巴尔虎右旗\", \"阿拉坦额莫勒镇\", \"新巴尔虎左旗\", \"阿穆古郎镇\", \"陈巴尔虎旗\", \"巴彦库仁镇\", \"鄂伦春自治旗\", \"阿里河镇\", \"鄂温克族自治旗\", \"巴彦托海镇\", \"莫力达瓦达斡尔族自治旗\", \"尼尔基镇\"] }, { name: \"鄂尔多斯市\", districtAndCounty: [\"东胜区\", \"达拉特旗\", \"树林召镇\", \"准格尔旗\", \"薛家湾镇\", \"鄂托克前旗\", \"敖勒召其镇\", \"鄂托克旗\", \"乌兰镇\", \"杭锦旗\", \"锡尼镇\", \"乌审旗\", \"嘎鲁图镇\", \"伊金霍洛旗\", \"阿勒腾席热镇\"] }, { name: \"乌兰察布市\", districtAndCounty: [\"集宁区\", \"丰镇市\", \"卓资县\", \"卓资山镇\", \"化德县\", \"长顺镇\", \"商都县\", \"商都镇\", \"兴和县\", \"城关镇\", \"凉城县\", \"岱海镇\", \"察哈尔右翼前旗\", \"土贵乌拉镇\", \"察哈尔右翼中旗\", \"科布尔镇\", \"察哈尔右翼后旗\", \"白音察干镇\", \"四子王旗\", \"乌兰花镇\"] }, { name: \"巴彦淖尔市\", districtAndCounty: [\"临河区\", \"五原县\", \"隆兴昌镇\", \"磴口县\", \"巴彦高勒镇\", \"乌拉特前旗\", \"乌拉山镇\", \"乌拉特中旗\", \"海流图镇\", \"乌拉特后旗\", \"巴音宝力格镇\", \"杭锦后旗\", \"陕坝镇\"] }, { name: \"兴安盟\", districtAndCounty: [\"乌兰浩特市\", \"阿尔山市\", \"突泉县\", \"突泉镇\", \"科尔沁右翼前旗\", \"大坝沟镇\", \"科尔沁右翼中旗\", \"巴彦呼硕镇\", \"扎赉特旗\", \"音德尔镇\"] }, { name: \"锡林郭勒盟\", districtAndCounty: [\"锡林浩特市\", \"二连浩特市\", \"多伦县\", \"多伦淖尔镇\", \"阿巴嘎旗\", \"别力古台镇\", \"苏尼特左旗\", \"满都拉图镇\", \"苏尼特右旗\", \"赛汉塔拉镇\", \"东乌珠穆沁旗\", \"乌里雅斯太镇\", \"西乌珠穆沁旗\", \"巴拉嘎尔郭勒镇\", \"太仆寺旗\", \"宝昌镇\", \"镶黄旗\", \"新宝拉格镇\", \"正镶白旗\", \"明安图镇\", \"正蓝旗\", \"上都镇\"] }, {name: \"阿拉善盟\", districtAndCounty: [\"巴彦浩特镇\", \"阿拉善右旗\", \"额肯呼都格镇\", \"额济纳旗\", \"达来呼布镇\"]}]}, { name: \"辽宁省\", city: [{ name: \"沈阳市\", districtAndCounty: [\"沈河区\", \"和平区\", \"大东区\", \"皇姑区\", \"铁西区\", \"苏家屯区\", \"东陵区\", \"新城子区\", \"于洪区\", \"新民市\", \"辽中县\", \"辽中镇\", \"康平县\", \"康平镇\", \"法库县\", \"法库镇\"] }, { name: \"朝阳市\", districtAndCounty: [\"双塔区\", \"龙城区\", \"北票市\", \"凌源市\", \"朝阳县\", \"朝阳市双塔区\", \"建平县\", \"喀喇沁左翼蒙古族自治县\", \"大城子镇\"] }, { name: \"阜新市\", districtAndCounty: [\"海州区\", \"新邱区\", \"太平区\", \"清河门区\", \"细河区\", \"彰武县\", \"彰武镇\", \"阜新蒙古族自治县\", \"阜新镇\"] }, { name: \"铁岭市\", districtAndCounty: [\"银州区\", \"清河区\", \"调兵山市\", \"开原市\", \"铁岭县\", \"铁岭市银州区\", \"西丰县\", \"西丰镇\", \"昌图县\", \"昌图镇\"] }, { name: \"抚顺市\", districtAndCounty: [\"顺城区\", \"新抚区\", \"东洲区\", \"望花区\", \"抚顺县\", \"抚顺市顺城区\", \"新宾满族自治县\", \"新宾镇\", \"清原满族自治县\", \"清原镇\"] }, {name: \"本溪市\", districtAndCounty: [\"平山区\", \"溪湖区\", \"明山区\", \"南芬区\", \"本溪满族自治县\", \"小市镇\", \"桓仁满族自治县\", \"桓仁镇\"]}, { name: \"辽阳市\", districtAndCounty: [\"白塔区\", \"文圣区\", \"宏伟区\", \"弓长岭区\", \"太子河区\", \"灯塔市\", \"辽阳县\", \"首山镇\"] }, { name: \"鞍山市\", districtAndCounty: [\"铁东区\", \"铁西区\", \"立山区\", \"千山区\", \"海城市\", \"台安县\", \"台安镇\", \"岫岩满族自治县\", \"岫岩镇\"] }, {name: \"丹东市\", districtAndCounty: [\"振兴区\", \"元宝区\", \"振安区\", \"凤城市\", \"东港市\", \"宽甸满族自治县\", \"宽甸镇\"]}, { name: \"大连市\", districtAndCounty: [\"西岗区\", \"中山区\", \"沙河口区\", \"甘井子区\", \"旅顺口区\", \"金州区\", \"瓦房店市\", \"普兰店市\", \"庄河市\", \"长海县\", \"大长山岛镇\"] }, {name: \"营口市\", districtAndCounty: [\"站前区\", \"西市区\", \"鲅鱼圈区\", \"老边区\", \"大石桥市\", \"盖州市\"]}, { name: \"盘锦市\", districtAndCounty: [\"兴隆台区\", \"双台子区\", \"大洼县\", \"大洼镇\", \"盘山县\", \"盘锦市双台子区\"] }, {name: \"锦州市\", districtAndCounty: [\"太和区\", \"古塔区\", \"凌河区\", \"凌海市\", \"北宁市\", \"黑山县\", \"黑山镇\", \"义县\", \"义州镇\"]}, { name: \"葫芦岛市\", districtAndCounty: [\"龙港区\", \"连山区\", \"南票区\", \"兴城市\", \"绥中县\", \"绥中镇\", \"建昌县\", \"建昌镇\"] }]}, { name: \"吉林省\", city: [{ name: \"长春市\", districtAndCounty: [\"朝阳区\", \"南关区\", \"宽城区\", \"二道区\", \"绿园区\", \"双阳区\", \"德惠市\", \"九台市\", \"榆树市\", \"农安县\", \"农安镇\"] }, {name: \"白城市\", districtAndCounty: [\"洮北区\", \"大安市\", \"洮南市\", \"镇赉县\", \"镇赉镇\", \"通榆县\", \"开通镇\"]}, { name: \"松原市\", districtAndCounty: [\"宁江区\", \"扶余县\", \"三岔河镇\", \"长岭县\", \"长岭镇\", \"乾安县\", \"乾安镇\", \"前郭尔罗斯蒙古族自治县\", \"前郭镇\"] }, { name: \"吉林市\", districtAndCounty: [\"船营区\", \"龙潭区\", \"昌邑区\", \"丰满区\", \"磐石市\", \"蛟河市\", \"桦甸市\", \"舒兰市\", \"永吉县\", \"口前镇\"] }, {name: \"四平市\", districtAndCounty: [\"铁西区\", \"铁东区\", \"双辽市\", \"公主岭市\", \"梨树县\", \"梨树镇\", \"伊通满族自治县\", \"伊通镇\"]}, { name: \"辽源市\", districtAndCounty: [\"龙山区\", \"西安区\", \"东丰县\", \"东丰镇\", \"东辽县\", \"白泉镇\"] }, { name: \"通化市\", districtAndCounty: [\"东昌区\", \"二道江区\", \"梅河口市\", \"集安市\", \"通化县\", \"快大茂镇\", \"辉南县\", \"朝阳镇\", \"柳河县\", \"柳河镇\"] }, { name: \"白山市\", districtAndCounty: [\"八道江区\", \"临江市\", \"江源县\", \"孙家堡子镇\", \"抚松县\", \"抚松镇\", \"靖宇县\", \"靖宇镇\", \"长白朝鲜族自治县\", \"长白镇\"] }, {name: \"延边州\", districtAndCounty: [\"延吉市\", \"图们市\", \"敦化市\", \"珲春市\", \"龙井市\", \"和龙市\", \"汪清县\", \"汪清镇\", \"安图县\", \"明月镇\"]}]}, { name: \"黑龙江省\", city: [{ name: \"哈尔滨市\", districtAndCounty: [\"松北区\", \"道里区\", \"南岗区\", \"道外区\", \"香坊区\", \"动力区\", \"平房区\", \"呼兰区\", \"双城市\", \"尚志市\", \"五常市\", \"阿城市\", \"依兰县\", \"依兰镇\", \"方正县\", \"方正镇\", \"宾县\", \"宾州镇\", \"巴彦县\", \"巴彦镇\", \"木兰县\", \"木兰镇\", \"通河县\", \"通河镇\", \"延寿县\", \"延寿镇\"] }, { name: \"齐齐哈尔市\", districtAndCounty: [\"建华区\", \"龙沙区\", \"铁锋区\", \"昂昂溪区\", \"富拉尔基区\", \"碾子山区\", \"梅里斯达斡尔族区\", \"讷河市\", \"龙江县\", \"龙江镇\", \"依安县\", \"依安镇\", \"泰来县\", \"泰来镇\", \"甘南县\", \"甘南镇\", \"富裕县\", \"富裕镇\", \"克山县\", \"克山镇\", \"克东县\", \"克东镇\", \"拜泉县\", \"拜泉镇\"] }, {name: \"七台河市\", districtAndCounty: [\"桃山区\", \"新兴区\", \"茄子河区\", \"勃利县\", \"勃利镇\"]}, { name: \"黑河市\", districtAndCounty: [\"爱辉区\", \"北安市\", \"五大连池市\", \"嫩江县\", \"嫩江镇\", \"逊克县\", \"边疆镇\", \"孙吴县\", \"孙吴镇\"] }, { name: \"大庆市\", districtAndCounty: [\"萨尔图区\", \"龙凤区\", \"让胡路区\", \"大同区\", \"红岗区\", \"肇州县\", \"肇州镇\", \"肇源县\", \"肇源镇\", \"林甸县\", \"林甸镇\", \"杜尔伯特蒙古族自治县\", \"泰康镇\"] }, { name: \"鹤岗市\", districtAndCounty: [\"兴山区\", \"向阳区\", \"工农区\", \"南山区\", \"兴安区\", \"东山区\", \"萝北县\", \"凤翔镇\", \"绥滨县\", \"绥滨镇\"] }, { name: \"伊春市\", districtAndCounty: [\"伊春区\", \"南岔区\", \"友好区\", \"西林区\", \"翠峦区\", \"新青区\", \"美溪区\", \"金山屯区\", \"五营区\", \"乌马河区\", \"汤旺河区\", \"带岭区\", \"乌伊岭区\", \"红星区\", \"上甘岭区\", \"铁力市\", \"嘉荫县\", \"朝阳镇\"] }, { name: \"佳木斯市\", districtAndCounty: [\"前进区\", \"永红区\", \"向阳区\", \"东风区\", \"郊区\", \"同江市\", \"富锦市\", \"桦南县\", \"桦南镇\", \"桦川县\", \"悦来镇\", \"汤原县\", \"汤原镇\", \"抚远县\", \"抚远镇\"] }, { name: \"双鸭山市\", districtAndCounty: [\"尖山区\", \"岭东区\", \"四方台区\", \"宝山区\", \"集贤县\", \"福利镇\", \"友谊县\", \"友谊镇\", \"宝清县\", \"宝清镇\", \"饶河县\", \"饶河镇\"] }, { name: \"鸡西市\", districtAndCounty: [\"鸡冠区\", \"恒山区\", \"滴道区\", \"梨树区\", \"城子河区\", \"麻山区\", \"虎林市\", \"密山市\", \"鸡东县\", \"鸡东镇\"] }, { name: \"牡丹江市\", districtAndCounty: [\"爱民区\", \"东安区\", \"阳明区\", \"西安区\", \"穆棱市\", \"绥芬河市\", \"海林市\", \"宁安市\", \"东宁县\", \"东宁镇\", \"林口县\", \"林口镇\"] }, { name: \"绥化市\", districtAndCounty: [\"北林区\", \"安达市\", \"肇东市\", \"海伦市\", \"望奎县\", \"望奎镇\", \"兰西县\", \"兰西镇\", \"青冈县\", \"青冈镇\", \"庆安县\", \"庆安镇\", \"明水县\", \"明水镇\", \"绥棱县\", \"绥棱镇\"] }, {name: \"大兴安岭地区\", districtAndCounty: [\"呼玛县\", \"呼玛镇\", \"塔河县\", \"塔河镇\", \"漠河县\", \"西林吉镇\"]}]}, { name: \"江苏省\", city: [{ name: \"南京市\", districtAndCounty: [\"玄武区\", \"白下区\", \"秦淮区\", \"建邺区\", \"鼓楼区\", \"下关区\", \"浦口区\", \"六合区\", \"栖霞区\", \"雨花台区\", \"江宁区\", \"溧水县\", \"永阳镇\", \"高淳县\", \"淳溪镇\"] }, { name: \"徐州市\", districtAndCounty: [\"云龙区\", \"鼓楼区\", \"九里区\", \"贾汪区\", \"泉山区\", \"邳州市\", \"新沂市\", \"铜山县\", \"铜山镇\", \"睢宁县\", \"睢城镇\", \"沛县\", \"沛城镇\", \"丰县\", \"凤城镇\"] }, { name: \"连云港市\", districtAndCounty: [\"新浦区\", \"连云区\", \"海州区\", \"赣榆县\", \"青口镇\", \"灌云县\", \"伊山镇\", \"东海县\", \"牛山镇\", \"灌南县\", \"新安镇\"] }, {name: \"宿迁市\", districtAndCounty: [\"宿城区\", \"宿豫区\", \"沭阳县\", \"沭城镇\", \"泗阳县\", \"众兴镇\", \"泗洪县\", \"青阳镇\"]}, { name: \"淮安市\", districtAndCounty: [\"清河区\", \"清浦区\", \"楚州区\", \"淮阴区\", \"金湖县\", \"黎城镇\", \"盱眙县\", \"盱城镇\", \"洪泽县\", \"高良涧镇\", \"涟水县\", \"涟城镇\"] }, { name: \"盐城市\", districtAndCounty: [\"亭湖区\", \"盐都区\", \"东台市\", \"大丰市\", \"射阳县\", \"合德镇\", \"阜宁县\", \"阜城镇\", \"滨海县\", \"东坎镇\", \"响水县\", \"响水镇\", \"建湖县\", \"近湖镇\"] }, {name: \"扬州市\", districtAndCounty: [\"维扬区\", \"广陵区\", \"邗江区\", \"仪征市\", \"江都市\", \"高邮市\", \"宝应县\", \"安宜镇\"]}, { name: \"泰州市\", districtAndCounty: [\"海陵区\", \"高港区\", \"靖江市\", \"泰兴市\", \"姜堰市\", \"兴化市\"] }, { name: \"南通市\", districtAndCounty: [\"崇川区\", \"港闸区\", \"海门市\", \"启东市\", \"通州市\", \"如皋市\", \"如东县\", \"掘港镇\", \"海安县\", \"海安镇\"] }, {name: \"镇江市\", districtAndCounty: [\"京口区\", \"润州区\", \"丹徒区\", \"扬中市\", \"丹阳市\", \"句容市\"]}, { name: \"常州市\", districtAndCounty: [\"钟楼区\", \"天宁区\", \"戚墅堰区\", \"新北区\", \"武进区\", \"金坛市\", \"溧阳市\"] }, {name: \"无锡市\", districtAndCounty: [\"崇安区\", \"南长区\", \"北塘区\", \"滨湖区\", \"惠山区\", \"锡山区\", \"江阴市\", \"宜兴市\"]}, { name: \"苏州市\", districtAndCounty: [\"金阊区\", \"沧浪区\", \"平江区\", \"虎丘区\", \"吴中区\", \"相城区\", \"吴江市\", \"昆山市\", \"太仓市\", \"常熟市\", \"张家港市\"] }]}, { name: \"浙江省\", city: [{ name: \"杭州市\", districtAndCounty: [\"拱墅区\", \"上城区\", \"下城区\", \"江干区\", \"西湖区\", \"滨江区\", \"余杭区\", \"萧山区\", \"临安市\", \"富阳市\", \"建德市\", \"桐庐县\", \"淳安县\", \"千岛湖镇\"] }, {name: \"湖州市\", districtAndCounty: [\"吴兴区\", \"南浔区\", \"长兴县\", \"雉城镇\", \"德清县\", \"武康镇\", \"安吉县\", \"递铺镇\"]}, { name: \"嘉兴市\", districtAndCounty: [\"南湖区\", \"秀洲区\", \"平湖市\", \"海宁市\", \"桐乡市\", \"嘉善县\", \"魏塘镇\", \"海盐县\", \"武原镇\"] }, {name: \"舟山市\", districtAndCounty: [\"定海区\", \"普陀区\", \"岱山县\", \"高亭镇\", \"嵊泗县\", \"菜园镇\"]}, { name: \"宁波市\", districtAndCounty: [\"海曙区\", \"江东区\", \"江北区\", \"北仑区\", \"镇海区\", \"鄞州区\", \"慈溪市\", \"余姚市\", \"奉化市\", \"宁海县\", \"象山县\"] }, {name: \"绍兴市\", districtAndCounty: [\"越城区\", \"诸暨市\", \"上虞市\", \"嵊州市\", \"绍兴县\", \"新昌县\", \"城关镇\"]}, { name: \"衢州市\", districtAndCounty: [\"柯城区\", \"衢江区\", \"江山市\", \"常山县\", \"天马镇\", \"开化县\", \"城关镇\", \"龙游县\"] }, { name: \"金华市\", districtAndCounty: [\"婺城区\", \"金东区\", \"兰溪市\", \"永康市\", \"义乌市\", \"东阳市\", \"武义县\", \"浦江县\", \"磐安县\", \"安文镇\"] }, { name: \"台州市\", districtAndCounty: [\"椒江区\", \"黄岩区\", \"路桥区\", \"临海市\", \"温岭市\", \"三门县\", \"海游镇\", \"天台县\", \"仙居县\", \"玉环县\", \"珠港镇\"] }, { name: \"温州市\", districtAndCounty: [\"鹿城区\", \"龙湾区\", \"瓯海区\", \"瑞安市\", \"乐清市\", \"永嘉县\", \"上塘镇\", \"文成县\", \"大峃镇\", \"平阳县\", \"昆阳镇\", \"泰顺县\", \"罗阳镇\", \"洞头县\", \"北岙镇\", \"苍南县\", \"灵溪镇\"] }, { name: \"丽水市\", districtAndCounty: [\"莲都区\", \"龙泉市\", \"缙云县\", \"五云镇\", \"青田县\", \"鹤城镇\", \"云和县\", \"云和镇\", \"遂昌县\", \"妙高镇\", \"松阳县\", \"西屏镇\", \"庆元县\", \"松源镇\", \"景宁畲族自治县\", \"鹤溪镇\"] }]}, { name: \"安徽省\", city: [{ name: \"合肥市\", districtAndCounty: [\"庐阳区\", \"瑶海区\", \"蜀山区\", \"包河区\", \"长丰县\", \"水湖镇\", \"肥东县\", \"店埠镇\", \"肥西县\", \"上派镇\"] }, {name: \"宿州市\", districtAndCounty: [\"埇桥区\", \"砀山县\", \"砀城镇\", \"萧县\", \"龙城镇\", \"灵璧县\", \"灵城镇\", \"泗县\", \"泗城镇\"]}, { name: \"淮北市\", districtAndCounty: [\"相山区\", \"杜集区\", \"烈山区\", \"濉溪县\", \"濉溪镇\"] }, {name: \"亳州市\", districtAndCounty: [\"谯城区\", \"涡阳县\", \"城关镇\", \"蒙城县\", \"城关镇\", \"利辛县\", \"城关镇\"]}, { name: \"阜阳市\", districtAndCounty: [\"颍州区\", \"颍东区\", \"颍泉区\", \"界首市\", \"临泉县\", \"城关镇\", \"太和县\", \"城关镇\", \"阜南县\", \"城关镇\", \"颍上县\", \"慎城镇\"] }, { name: \"蚌埠市\", districtAndCounty: [\"蚌山区\", \"龙子湖区\", \"禹会区\", \"淮上区\", \"怀远县\", \"城关镇\", \"五河县\", \"城关镇\", \"固镇县\", \"城关镇\"] }, {name: \"淮南市\", districtAndCounty: [\"田家庵区\", \"大通区\", \"谢家集区\", \"八公山区\", \"潘集区\", \"凤台县\", \"城关镇\"]}, { name: \"滁州市\", districtAndCounty: [\"琅区\", \"南谯区\", \"明光市\", \"天长市\", \"来安县\", \"新安镇\", \"全椒县\", \"襄河镇\", \"定远县\", \"定城镇\", \"凤阳县\", \"府城镇\"] }, {name: \"马鞍山市\", districtAndCounty: [\"雨山区\", \"花山区\", \"金家庄区\", \"当涂县\", \"姑孰镇\"]}, { name: \"芜湖市\", districtAndCounty: [\"镜湖区\", \"弋江区\", \"三山区\", \"鸠江区\", \"芜湖县\", \"湾镇\", \"繁昌县\", \"繁阳镇\", \"南陵县\", \"籍山镇\"] }, {name: \"铜陵市\", districtAndCounty: [\"铜官山区\", \"狮子山区\", \"郊区\", \"铜陵县\", \"五松镇\"]}, { name: \"安庆市\", districtAndCounty: [\"迎江区\", \"大观区\", \"宜秀区\", \"桐城市\", \"怀宁县\", \"高河镇\", \"枞阳县\", \"枞阳镇\", \"潜山县\", \"梅城镇\", \"太湖县\", \"晋熙镇\", \"宿松县\", \"孚玉镇\", \"望江县\", \"雷阳镇\", \"岳西县\", \"天堂镇\"] }, { name: \"黄山市\", districtAndCounty: [\"屯溪区\", \"黄山区\", \"徽州区\", \"歙县\", \"徽城镇\", \"休宁县\", \"海阳镇\", \"黟县\", \"碧阳镇\", \"祁门县\", \"祁山镇\"] }, { name: \"六安市\", districtAndCounty: [\"金安区\", \"裕安区\", \"寿县\", \"寿春镇\", \"霍邱县\", \"城关镇\", \"舒城县\", \"城关镇\", \"金寨县\", \"梅山镇\", \"霍山县\", \"衡山镇\"] }, {name: \"巢湖市\", districtAndCounty: [\"居巢区\", \"庐江县\", \"庐城镇\", \"无为县\", \"无城镇\", \"含山县\", \"环峰镇\", \"和县\", \"历阳镇\"]}, { name: \"池州市\", districtAndCounty: [\"贵池区\", \"东至县\", \"尧渡镇\", \"石台县\", \"七里镇\", \"青阳县\", \"蓉城镇\"] }, { name: \"宣城市\", districtAndCounty: [\"宣州区\", \"宁国市\", \"郎溪县\", \"建平镇\", \"广德县\", \"桃州镇\", \"泾县\", \"泾川镇\", \"旌德县\", \"旌阳镇\", \"绩溪县\", \"华阳镇\"] }]}, { name: \"福建省\", city: [{ name: \"福州市\", districtAndCounty: [\"鼓楼区\", \"台江区\", \"仓山区\", \"马尾区\", \"晋安区\", \"福清市\", \"长乐市\", \"闽侯县\", \"连江县\", \"凤城镇\", \"罗源县\", \"凤山镇\", \"闽清县\", \"梅城镇\", \"永泰县\", \"樟城镇\", \"平潭县\", \"潭城镇\"] }, { name: \"南平市\", districtAndCounty: [\"延平区\", \"邵武市\", \"武夷山市\", \"建瓯市\", \"建阳市\", \"顺昌县\", \"浦城县\", \"光泽县\", \"杭川镇\", \"松溪县\", \"松源镇\", \"政和县\", \"熊山镇\"] }, {name: \"莆田市\", districtAndCounty: [\"城厢区\", \"涵江区\", \"荔城区\", \"秀屿区\", \"仙游县\"]}, { name: \"三明市\", districtAndCounty: [\"梅列区\", \"三元区\", \"永安市\", \"明溪县\", \"雪峰镇\", \"清流县\", \"龙津镇\", \"宁化县\", \"翠江镇\", \"大田县\", \"均溪镇\", \"尤溪县\", \"城关镇\", \"沙县\", \"将乐县\", \"古镛镇\", \"泰宁县\", \"杉城镇\", \"建宁县\", \"濉城镇\"] }, { name: \"泉州市\", districtAndCounty: [\"鲤城区\", \"丰泽区\", \"洛江区\", \"泉港区\", \"石狮市\", \"晋江市\", \"南安市\", \"惠安县\", \"螺城镇\", \"安溪县\", \"凤城镇\", \"永春县\", \"桃城镇\", \"德化县\", \"浔中镇\", \"金门县\", \"☆\"] }, {name: \"厦门市\", districtAndCounty: [\"思明区\", \"海沧区\", \"湖里区\", \"集美区\", \"同安区\", \"翔安区\"]}, { name: \"漳州市\", districtAndCounty: [\"芗城区\", \"龙文区\", \"龙海市\", \"云霄县\", \"云陵镇\", \"漳浦县\", \"绥安镇\", \"诏安县\", \"南诏镇\", \"长泰县\", \"武安镇\", \"东山县\", \"西埔镇\", \"南靖县\", \"山城镇\", \"平和县\", \"小溪镇\", \"华安县\", \"华丰镇\"] }, { name: \"龙岩市\", districtAndCounty: [\"新罗区\", \"漳平市\", \"长汀县\", \"汀州镇\", \"永定县\", \"凤城镇\", \"上杭县\", \"临江镇\", \"武平县\", \"平川镇\", \"连城县\", \"莲峰镇\"] }, { name: \"宁德市\", districtAndCounty: [\"蕉城区\", \"福安市\", \"福鼎市\", \"寿宁县\", \"鳌阳镇\", \"霞浦县\", \"柘荣县\", \"双城镇\", \"屏南县\", \"古峰镇\", \"古田县\", \"周宁县\", \"狮城镇\"] }]}, { name: \"江西省\", city: [{ name: \"南昌市\", districtAndCounty: [\"东湖区\", \"西湖区\", \"青云谱区\", \"湾里区\", \"青山湖区\", \"南昌县\", \"莲塘镇\", \"新建县\", \"长堎镇\", \"安义县\", \"龙津镇\", \"进贤县\", \"民和镇\"] }, { name: \"九江市\", districtAndCounty: [\"浔阳区\", \"庐山区\", \"瑞昌市\", \"九江县\", \"沙河街镇\", \"武宁县\", \"新宁镇\", \"修水县\", \"义宁镇\", \"永修县\", \"涂埠镇\", \"德安县\", \"蒲亭镇\", \"星子县\", \"南康镇\", \"都昌县\", \"都昌镇\", \"湖口县\", \"双钟镇\", \"彭泽县\", \"龙城镇\"] }, {name: \"景德镇市\", districtAndCounty: [\"珠山区\", \"昌江区\", \"乐平市\", \"浮梁县\", \"浮梁镇\"]}, { name: \"鹰潭市\", districtAndCounty: [\"月湖区\", \"贵溪市\", \"余江县\", \"邓埠镇\"] }, {name: \"新余市\", districtAndCounty: [\"渝水区\", \"分宜县\", \"分宜镇\"]}, { name: \"萍乡市\", districtAndCounty: [\"安源区\", \"湘东区\", \"莲花县\", \"琴亭镇\", \"上栗县\", \"上栗镇\", \"芦溪县\", \"芦溪镇\"] }, { name: \"赣州市\", districtAndCounty: [\"章贡区\", \"瑞金市\", \"南康市\", \"赣县\", \"梅林镇\", \"信丰县\", \"嘉定镇\", \"大余县\", \"南安镇\", \"上犹县\", \"东山镇\", \"崇义县\", \"横水镇\", \"安远县\", \"欣山镇\", \"龙南县\", \"龙南镇\", \"定南县\", \"历市镇\", \"全南县\", \"城厢镇\", \"宁都县\", \"梅江镇\", \"于都县\", \"贡江镇\", \"兴国县\", \"潋江镇\", \"会昌县\", \"文武坝镇\", \"寻乌县\", \"长宁镇\", \"石城县\", \"琴江镇\"] }, { name: \"上饶市\", districtAndCounty: [\"信州区\", \"德兴市\", \"上饶县\", \"旭日镇\", \"广丰县\", \"永丰镇\", \"玉山县\", \"冰溪镇\", \"铅山县\", \"河口镇\", \"横峰县\", \"岑阳镇\", \"弋阳县\", \"弋江镇\", \"余干县\", \"玉亭镇\", \"鄱阳县\", \"鄱阳镇\", \"万年县\", \"陈营镇\", \"婺源县\", \"紫阳镇\"] }, { name: \"抚州市\", districtAndCounty: [\"临川区\", \"南城县\", \"建昌镇\", \"黎川县\", \"日峰镇\", \"南丰县\", \"琴城镇\", \"崇仁县\", \"巴山镇\", \"乐安县\", \"鳌溪镇\", \"宜黄县\", \"凤冈镇\", \"金溪县\", \"秀谷镇\", \"资溪县\", \"鹤城镇\", \"东乡县\", \"孝岗镇\", \"广昌县\", \"旴江镇\"] }, { name: \"宜春市\", districtAndCounty: [\"袁州区\", \"丰城市\", \"樟树市\", \"高安市\", \"奉新县\", \"冯川镇\", \"万载县\", \"上高县\", \"宜丰县\", \"新昌镇\", \"靖安县\", \"双溪镇\", \"铜鼓县\", \"永宁镇\"] }, { name: \"吉安市\", districtAndCounty: [\"吉州区\", \"青原区\", \"井冈山市\", \"厦坪镇\", \"吉安县\", \"敦厚镇\", \"吉水县\", \"文峰镇\", \"峡江县\", \"水边镇\", \"新干县\", \"金川镇\", \"永丰县\", \"恩江镇\", \"泰和县\", \"澄江镇\", \"遂川县\", \"泉江镇\", \"万安县\", \"芙蓉镇\", \"安福县\", \"平都镇\", \"永新县\", \"禾川镇\"] }]}, { name: \"山东省\", city: [{ name: \"济南市\", districtAndCounty: [\"市中区\", \"历下区\", \"槐荫区\", \"天桥区\", \"历城区\", \"长清区\", \"章丘市\", \"平阴县\", \"平阴镇\", \"济阳县\", \"济阳镇\", \"商河县\"] }, { name: \"青岛市\", districtAndCounty: [\"市南区\", \"市北区\", \"四方区\", \"黄岛区\", \"崂山区\", \"城阳区\", \"李沧区\", \"胶州市\", \"即墨市\", \"平度市\", \"胶南市\", \"莱西市\"] }, {name: \"聊城市\", districtAndCounty: [\"东昌府区\", \"临清市\", \"阳谷县\", \"莘县\", \"茌平县\", \"东阿县\", \"冠县\", \"冠城镇\", \"高唐县\"]}, { name: \"德州市\", districtAndCounty: [\"德城区\", \"乐陵市\", \"禹城市\", \"陵县\", \"陵城镇\", \"平原县\", \"夏津县\", \"夏津镇\", \"武城县\", \"武城镇\", \"齐河县\", \"晏城镇\", \"临邑县\", \"宁津县\", \"宁津镇\", \"庆云县\", \"庆云镇\"] }, {name: \"东营市\", districtAndCounty: [\"东营区\", \"河口区\", \"垦利县\", \"垦利镇\", \"利津县\", \"利津镇\", \"广饶县\", \"广饶镇\"]}, { name: \"淄博市\", districtAndCounty: [\"张店区\", \"淄川区\", \"博山区\", \"临淄区\", \"周村区\", \"桓台县\", \"索镇\", \"高青县\", \"田镇\", \"沂源县\", \"南麻镇\"] }, { name: \"潍坊市\", districtAndCounty: [\"潍城区\", \"寒亭区\", \"坊子区\", \"奎文区\", \"安丘市\", \"昌邑市\", \"高密市\", \"青州市\", \"诸城市\", \"寿光市\", \"临朐县\", \"昌乐县\"] }, { name: \"烟台市\", districtAndCounty: [\"莱山区\", \"芝罘区\", \"福山区\", \"牟平区\", \"栖霞市\", \"海阳市\", \"龙口市\", \"莱阳市\", \"莱州市\", \"蓬莱市\", \"招远市\", \"长岛县\", \"南长山镇\"] }, {name: \"威海市\", districtAndCounty: [\"环翠区\", \"荣成市\", \"乳山市\", \"文登市\"]}, { name: \"日照市\", districtAndCounty: [\"东港区\", \"岚山区\", \"五莲县\", \"洪凝镇\", \"莒县\", \"城阳镇\"] }, { name: \"临沂市\", districtAndCounty: [\"兰山区\", \"罗庄区\", \"河东区\", \"郯城县\", \"郯城镇\", \"苍山县\", \"卞庄镇\", \"莒南县\", \"十字路镇\", \"沂水县\", \"沂水镇\", \"蒙阴县\", \"蒙阴镇\", \"平邑县\", \"平邑镇\", \"费县\", \"费城镇\", \"沂南县\", \"界湖镇\", \"临沭县\", \"临沭镇\"] }, {name: \"枣庄市\", districtAndCounty: [\"薛城区\", \"市中区\", \"峄城区\", \"台儿庄区\", \"山亭区\", \"滕州市\"]}, { name: \"济宁市\", districtAndCounty: [\"市中区\", \"任城区\", \"曲阜市\", \"兖州市\", \"邹城市\", \"微山县\", \"鱼台县\", \"谷亭镇\", \"金乡县\", \"金乡镇\", \"嘉祥县\", \"嘉祥镇\", \"汶上县\", \"汶上镇\", \"泗水县\", \"梁山县\", \"梁山镇\"] }, {name: \"泰安市\", districtAndCounty: [\"泰山区\", \"岱岳区\", \"新泰市\", \"肥城市\", \"宁阳县\", \"宁阳镇\", \"东平县\", \"东平镇\"]}, { name: \"莱芜市\", districtAndCounty: [\"莱城区\", \"钢城区\"] }, { name: \"滨州市\", districtAndCounty: [\"滨城区\", \"惠民县\", \"惠民镇\", \"阳信县\", \"阳信镇\", \"无棣县\", \"无棣镇\", \"沾化县\", \"富国镇\", \"博兴县\", \"博兴镇\", \"邹平县\"] }, { name: \"菏泽市\", districtAndCounty: [\"牡丹区\", \"曹县\", \"曹城镇\", \"定陶县\", \"定陶镇\", \"成武县\", \"成武镇\", \"单县\", \"单城镇\", \"巨野县\", \"巨野镇\", \"郓城县\", \"郓城镇\", \"鄄城县\", \"鄄城镇\", \"东明县\", \"城关镇\"] }]}, { name: \"河南省\", city: [{ name: \"郑州市\", districtAndCounty: [\"中原区\", \"二七区\", \"管城回族区\", \"金水区\", \"上街区\", \"惠济区\", \"新郑市\", \"登封市\", \"新密市\", \"巩义市\", \"荥阳市\", \"中牟县\", \"城关镇\"] }, { name: \"开封市\", districtAndCounty: [\"鼓楼区\", \"龙亭区\", \"顺河回族区\", \"禹王台区\", \"金明区\", \"杞县\", \"城关镇\", \"通许县\", \"城关镇\", \"尉氏县\", \"城关镇\", \"开封县\", \"城关镇\", \"兰考县\", \"城关镇\"] }, {name: \"三门峡市\", districtAndCounty: [\"湖滨区\", \"义马市\", \"灵宝市\", \"渑池县\", \"城关镇\", \"陕县\", \"大营镇\", \"卢氏县\", \"城关镇\"]}, { name: \"洛阳市\", districtAndCounty: [\"西工区\", \"老城区\", \"瀍河回族区\", \"涧西区\", \"吉利区\", \"洛龙区\", \"偃师市\", \"孟津县\", \"城关镇\", \"新安县\", \"城关镇\", \"栾川县\", \"城关镇\", \"嵩县\", \"城关镇\", \"汝阳县\", \"城关镇\", \"宜阳县\", \"城关镇\", \"洛宁县\", \"城关镇\", \"伊川县\", \"城关镇\"] }, { name: \"焦作市\", districtAndCounty: [\"解放区\", \"山阳区\", \"中站区\", \"马村区\", \"孟州市\", \"沁阳市\", \"修武县\", \"城关镇\", \"博爱县\", \"清化镇\", \"武陟县\", \"木城镇\", \"温县\", \"温泉镇\"] }, { name: \"新乡市\", districtAndCounty: [\"卫滨区\", \"红旗区\", \"凤泉区\", \"牧野区\", \"卫辉市\", \"辉县市\", \"新乡县\", \"新乡市红旗区\", \"获嘉县\", \"城关镇\", \"原阳县\", \"城关镇\", \"延津县\", \"城关镇\", \"封丘县\", \"城关镇\", \"长垣县\", \"城关镇\"] }, {name: \"鹤壁市\", districtAndCounty: [\"淇滨区\", \"山城区\", \"鹤山区\", \"浚县\", \"城关镇\", \"淇县\", \"朝歌镇\"]}, { name: \"安阳市\", districtAndCounty: [\"北关区\", \"文峰区\", \"殷都区\", \"龙安区\", \"林州市\", \"安阳县\", \"安阳市北关区\", \"汤阴县\", \"城关镇\", \"滑县\", \"道口镇\", \"内黄县\", \"城关镇\"] }, { name: \"濮阳市\", districtAndCounty: [\"华龙区\", \"清丰县\", \"城关镇\", \"南乐县\", \"城关镇\", \"范县\", \"城关镇\", \"台前县\", \"城关镇\", \"濮阳县\", \"城关镇\"] }, { name: \"商丘市\", districtAndCounty: [\"梁园区\", \"睢阳区\", \"永城市\", \"虞城县\", \"城关镇\", \"民权县\", \"城关镇\", \"宁陵县\", \"城关镇\", \"睢县\", \"城关镇\", \"夏邑县\", \"城关镇\", \"柘城县\", \"城关镇\"] }, { name: \"许昌市\", districtAndCounty: [\"魏都区\", \"禹州市\", \"长葛市\", \"许昌县\", \"许昌市魏都区\", \"鄢陵县\", \"安陵镇\", \"襄城县\", \"城关镇\"] }, {name: \"漯河市\", districtAndCounty: [\"源汇区\", \"郾城区\", \"召陵区\", \"舞阳县\", \"舞泉镇\", \"临颍县\", \"城关镇\"]}, { name: \"平顶山市\", districtAndCounty: [\"新华区\", \"卫东区\", \"湛河区\", \"石龙区\", \"舞钢市\", \"汝州市\", \"宝丰县\", \"城关镇\", \"叶县\", \"昆阳镇\", \"鲁山县\", \"鲁阳镇\", \"郏县\", \"城关镇\"] }, { name: \"南阳市\", districtAndCounty: [\"卧龙区\", \"宛城区\", \"邓州市\", \"南召县\", \"城关镇\", \"方城县\", \"城关镇\", \"西峡县\", \"镇平县\", \"城关镇\", \"内乡县\", \"城关镇\", \"淅川县\", \"社旗县\", \"赊店镇\", \"唐河县\", \"新野县\", \"城关镇\", \"桐柏县\", \"城关镇\"] }, { name: \"信阳市\", districtAndCounty: [\"河区\", \"平桥区\", \"息县\", \"城关镇\", \"淮滨县\", \"城关镇\", \"潢川县\", \"光山县\", \"固始县\", \"城关镇\", \"商城县\", \"城关镇\", \"罗山县\", \"城关镇\", \"新县\", \"新集镇\"] }, { name: \"周口市\", districtAndCounty: [\"川汇区\", \"项城市\", \"扶沟县\", \"城关镇\", \"西华县\", \"城关镇\", \"商水县\", \"城关镇\", \"太康县\", \"城关镇\", \"鹿邑县\", \"城关镇\", \"郸城县\", \"城关镇\", \"淮阳县\", \"城关镇\", \"沈丘县\", \"槐店镇\"] }, { name: \"驻马店市\", districtAndCounty: [\"驿城区\", \"确山县\", \"盘龙镇\", \"泌阳县\", \"泌水镇\", \"遂平县\", \"灈阳镇\", \"西平县\", \"上蔡县\", \"蔡都镇\", \"汝南县\", \"汝宁镇\", \"平舆县\", \"古槐镇\", \"新蔡县\", \"古吕镇\", \"正阳县\", \"真阳镇\"] }, {name: \"济源市\", districtAndCounty: []}]}, { name: \"湖北省\", city: [{ name: \"武汉市\", districtAndCounty: [\"江岸区\", \"江汉区\", \"硚口区\", \"汉阳区\", \"武昌区\", \"青山区\", \"洪山区\", \"东西湖区\", \"汉南区\", \"蔡甸区\", \"江夏区\", \"黄陂区\", \"新洲区\"] }, { name: \"十堰市\", districtAndCounty: [\"张湾区\", \"茅箭区\", \"丹江口市\", \"郧县\", \"城关镇\", \"竹山县\", \"城关镇\", \"房县\", \"城关镇\", \"郧西县\", \"城关镇\", \"竹溪县\", \"城关镇\"] }, { name: \"襄樊市\", districtAndCounty: [\"襄城区\", \"樊城区\", \"襄阳区\", \"老河口市\", \"枣阳市\", \"宜城市\", \"南漳县\", \"城关镇\", \"谷城县\", \"城关镇\", \"保康县\", \"城关镇\"] }, {name: \"荆门市\", districtAndCounty: [\"东宝区\", \"掇刀区\", \"钟祥市\", \"沙洋县\", \"沙洋镇\", \"京山县\", \"新市镇\"]}, { name: \"孝感市\", districtAndCounty: [\"孝南区\", \"应城市\", \"安陆市\", \"汉川市\", \"孝昌县\", \"花园镇\", \"大悟县\", \"城关镇\", \"云梦县\", \"城关镇\"] }, { name: \"黄冈市\", districtAndCounty: [\"黄州区\", \"麻城市\", \"武穴市\", \"红安县\", \"城关镇\", \"罗田县\", \"凤山镇\", \"英山县\", \"温泉镇\", \"浠水县\", \"清泉镇\", \"蕲春县\", \"漕河镇\", \"黄梅县\", \"黄梅镇\", \"团风县\", \"团风镇\"] }, {name: \"鄂州市\", districtAndCounty: [\"鄂城区\", \"梁子湖区\", \"华容区\"]}, { name: \"黄石市\", districtAndCounty: [\"黄石港区\", \"西塞山区\", \"下陆区\", \"铁山区\", \"大冶市\", \"阳新县\", \"兴国镇\"] }, { name: \"咸宁市\", districtAndCounty: [\"咸安区\", \"赤壁市\", \"嘉鱼县\", \"鱼岳镇\", \"通城县\", \"隽水镇\", \"崇阳县\", \"天城镇\", \"通山县\", \"通羊镇\"] }, { name: \"荆州市\", districtAndCounty: [\"沙市区\", \"荆州区\", \"石首市\", \"洪湖市\", \"松滋市\", \"江陵县\", \"郝穴镇\", \"公安县\", \"斗湖堤镇\", \"监利县\", \"容城镇\"] }, { name: \"宜昌市\", districtAndCounty: [\"西陵区\", \"伍家岗区\", \"点军区\", \"猇亭区\", \"夷陵区\", \"枝江市\", \"宜都市\", \"当阳市\", \"远安县\", \"鸣凤镇\", \"兴山县\", \"古夫镇\", \"秭归县\", \"茅坪镇\", \"长阳土家族自治县\", \"龙舟坪镇\", \"五峰土家族自治县\", \"五峰镇\"] }, {name: \"随州市\", districtAndCounty: [\"曾都区\", \"广水市\"]}, { name: \"省直辖县级行政单位\", districtAndCounty: [\"仙桃市\", \"天门市\", \"潜江市\", \"神农架林区\", \"松柏镇\"] }, { name: \"恩施州\", districtAndCounty: [\"恩施市\", \"利川市\", \"建始县\", \"业州镇\", \"巴东县\", \"信陵镇\", \"宣恩县\", \"珠山镇\", \"咸丰县\", \"高乐山镇\", \"来凤县\", \"翔凤镇\", \"鹤峰县\", \"容美镇\"] }]}, { name: \"湖南省\", city: [{ name: \"长沙市\", districtAndCounty: [\"长沙市\", \"岳麓区\", \"芙蓉区\", \"天心区\", \"开福区\", \"雨花区\", \"浏阳市\", \"长沙县\", \"星沙镇\", \"望城县\", \"高塘岭镇\", \"宁乡县\", \"玉潭镇\"] }, {name: \"张家界市\", districtAndCounty: [\"永定区\", \"武陵源区\", \"慈利县\", \"零阳镇\", \"桑植县\", \"澧源镇\"]}, { name: \"常德市\", districtAndCounty: [\"武陵区\", \"鼎城区\", \"津市市\", \"安乡县\", \"城关镇\", \"汉寿县\", \"龙阳镇\", \"澧县\", \"澧阳镇\", \"临澧县\", \"安福镇\", \"桃源县\", \"漳江镇\", \"石门县\", \"楚江镇\"] }, {name: \"益阳市\", districtAndCounty: [\"赫山区\", \"资阳区\", \"沅江市\", \"南县\", \"南洲镇\", \"桃江县\", \"桃花江镇\", \"安化县\", \"东坪镇\"]}, { name: \"岳阳市\", districtAndCounty: [\"岳阳楼区\", \"君山区\", \"云溪区\", \"汨罗市\", \"临湘市\", \"岳阳县\", \"荣家湾镇\", \"华容县\", \"城关镇\", \"湘阴县\", \"文星镇\", \"平江县\", \"汉昌镇\"] }, { name: \"株洲市\", districtAndCounty: [\"天元区\", \"荷塘区\", \"芦淞区\", \"石峰区\", \"醴陵市\", \"株洲县\", \"渌口镇\", \"攸县\", \"城关镇\", \"茶陵县\", \"城关镇\", \"炎陵县\", \"霞阳镇\"] }, {name: \"湘潭市\", districtAndCounty: [\"岳塘区\", \"雨湖区\", \"湘乡市\", \"韶山市\", \"湘潭县\", \"易俗河镇\"]}, { name: \"衡阳市\", districtAndCounty: [\"雁峰区\", \"珠晖区\", \"石鼓区\", \"蒸湘区\", \"南岳区\", \"常宁市\", \"耒阳市\", \"衡阳县\", \"西渡镇\", \"衡南县\", \"云集镇\", \"衡山县\", \"开云镇\", \"衡东县\", \"城关镇\", \"祁东县\", \"洪桥镇\"] }, { name: \"郴州市\", districtAndCounty: [\"北湖区\", \"苏仙区\", \"资兴市\", \"桂阳县\", \"城关镇\", \"永兴县\", \"城关镇\", \"宜章县\", \"城关镇\", \"嘉禾县\", \"城关镇\", \"临武县\", \"城关镇\", \"汝城县\", \"城关镇\", \"桂东县\", \"城关镇\", \"安仁县\", \"城关镇\"] }, { name: \"永州市\", districtAndCounty: [\"冷水滩区\", \"零陵区\", \"东安县\", \"白牙市镇\", \"道县\", \"道江镇\", \"宁远县\", \"舜陵镇\", \"江永县\", \"潇浦镇\", \"蓝山县\", \"塔峰镇\", \"新田县\", \"龙泉镇\", \"双牌县\", \"泷泊镇\", \"祁阳县\", \"浯溪镇\", \"江华瑶族自治县\", \"沱江镇\"] }, { name: \"邵阳市\", districtAndCounty: [\"双清区\", \"大祥区\", \"北塔区\", \"武冈市\", \"邵东县\", \"两市镇\", \"邵阳县\", \"塘渡口镇\", \"新邵县\", \"酿溪镇\", \"隆回县\", \"桃洪镇\", \"洞口县\", \"洞口镇\", \"绥宁县\", \"长铺镇\", \"新宁县\", \"金石镇\", \"城步苗族自治县\", \"儒林镇\"] }, { name: \"怀化市\", districtAndCounty: [\"鹤城区\", \"洪江市\", \"沅陵县\", \"沅陵镇\", \"辰溪县\", \"辰阳镇\", \"溆浦县\", \"卢峰镇\", \"中方县\", \"中方镇\", \"会同县\", \"林城镇\", \"麻阳苗族自治县\", \"高村镇\", \"新晃侗族自治县\", \"新晃镇\", \"芷江侗族自治县\", \"芷江镇\", \"靖州苗族侗族自治县\", \"渠阳镇\", \"通道侗族自治县\", \"双江镇\"] }, {name: \"娄底市\", districtAndCounty: [\"娄星区\", \"冷水江市\", \"涟源市\", \"双峰县\", \"永丰镇\", \"新化县\", \"上梅镇\"]}, { name: \"湘西州\", districtAndCounty: [\"吉首市\", \"泸溪县\", \"白沙镇\", \"凤凰县\", \"沱江镇\", \"花垣县\", \"花垣镇\", \"保靖县\", \"迁陵镇\", \"古丈县\", \"古阳镇\", \"永顺县\", \"灵溪镇\", \"龙山县\"] }]}, { name: \"广东省\", city: [{ name: \"广州市\", districtAndCounty: [\"越秀区\", \"荔湾区\", \"海珠区\", \"天河区\", \"白云区\", \"黄埔区\", \"番禺区\", \"花都区\", \"南沙区\", \"萝岗区\", \"增城市\", \"从化市\"] }, {name: \"深圳市\", districtAndCounty: [\"福田区\", \"罗湖区\", \"南山区\", \"宝安区\", \"龙岗区\", \"盐田区\"]}, { name: \"清远市\", districtAndCounty: [\"清城区\", \"英德市\", \"连州市\", \"佛冈县\", \"石角镇\", \"阳山县\", \"阳城镇\", \"清新县\", \"太和镇\", \"连山壮族瑶族自治县\", \"吉田镇\", \"连南瑶族自治县\", \"三江镇\"] }, { name: \"韶关市\", districtAndCounty: [\"浈江区\", \"武江区\", \"曲江区\", \"乐昌市\", \"南雄市\", \"始兴县\", \"太平镇\", \"仁化县\", \"仁化镇\", \"翁源县\", \"龙仙镇\", \"新丰县\", \"乳源瑶族自治县\", \"乳城镇\"] }, { name: \"河源市\", districtAndCounty: [\"源城区\", \"紫金县\", \"紫城镇\", \"龙川县\", \"老隆镇\", \"连平县\", \"元善镇\", \"和平县\", \"阳明镇\", \"东源县\", \"仙塘镇\"] }, { name: \"梅州市\", districtAndCounty: [\"梅江区\", \"兴宁市\", \"梅县\", \"程江镇\", \"大埔县\", \"湖寮镇\", \"丰顺县\", \"汤坑镇\", \"五华县\", \"水寨镇\", \"平远县\", \"大柘镇\", \"蕉岭县\", \"蕉城镇\"] }, {name: \"潮州市\", districtAndCounty: [\"湘桥区\", \"潮安县\", \"庵埠镇\", \"饶平县\", \"黄冈镇\"]}, { name: \"汕头市\", districtAndCounty: [\"金平区\", \"濠江区\", \"龙湖区\", \"潮阳区\", \"潮南区\", \"澄海区\", \"南澳县\", \"后宅镇\"] }, {name: \"揭阳市\", districtAndCounty: [\"榕城区\", \"普宁市\", \"揭东县\", \"曲溪镇\", \"揭西县\", \"河婆镇\", \"惠来县\", \"惠城镇\"]}, { name: \"汕尾市\", districtAndCounty: [\"城区\", \"陆丰市\", \"海丰县\", \"海城镇\", \"陆河县\", \"河田镇\"] }, {name: \"惠州市\", districtAndCounty: [\"惠城区\", \"惠阳区\", \"博罗县\", \"罗阳镇\", \"惠东县\", \"龙门县\"]}, { name: \"东莞市\", districtAndCounty: [] }, {name: \"珠海市\", districtAndCounty: [\"香洲区\", \"斗门区\", \"金湾区\"]}, {name: \"中山市\", districtAndCounty: []}, { name: \"江门市\", districtAndCounty: [\"江海区\", \"蓬江区\", \"新会区\", \"恩平市\", \"台山市\", \"开平市\", \"鹤山市\"] }, {name: \"佛山市\", districtAndCounty: [\"禅城区\", \"南海区\", \"顺德区\", \"三水区\", \"高明区\"]}, { name: \"肇庆市\", districtAndCounty: [\"端州区\", \"鼎湖区\", \"高要市\", \"四会市\", \"广宁县\", \"南街镇\", \"怀集县\", \"怀城镇\", \"封开县\", \"江口镇\", \"德庆县\"] }, {name: \"云浮市\", districtAndCounty: [\"云城区\", \"罗定市\", \"云安县\", \"六都镇\", \"新兴县\", \"新城镇\", \"郁南县\", \"都城镇\"]}, { name: \"阳江市\", districtAndCounty: [\"江城区\", \"阳春市\", \"阳西县\", \"织镇\", \"阳东县\", \"东城镇\"] }, {name: \"茂名市\", districtAndCounty: [\"茂南区\", \"茂港区\", \"化州市\", \"信宜市\", \"高州市\", \"电白县\", \"水东镇\"]}, { name: \"湛江市\", districtAndCounty: [\"赤坎区\", \"霞山区\", \"坡头区\", \"麻章区\", \"吴川市\", \"廉江市\", \"雷州市\", \"遂溪县\", \"遂城镇\", \"徐闻县\", \"撤销广州市东山区\", \"芳村区\", \"设立广州市南沙区\", \"萝岗区\"] }]}, { name: \"广西\", city: [{ name: \"南宁市\", districtAndCounty: [\"青秀区\", \"兴宁区\", \"江南区\", \"西乡塘区\", \"良庆区\", \"邕宁区\", \"武鸣县\", \"横县\", \"宾阳县\", \"上林县\", \"隆安县\", \"马山县\"] }, { name: \"桂林市\", districtAndCounty: [\"象山区\", \"叠彩区\", \"秀峰区\", \"七星区\", \"雁山区\", \"阳朔县\", \"阳朔镇\", \"临桂县\", \"临桂镇\", \"灵川县\", \"灵川镇\", \"全州县\", \"全州镇\", \"兴安县\", \"兴安镇\", \"永福县\", \"永福镇\", \"灌阳县\", \"灌阳镇\", \"资源县\", \"资源镇\", \"平乐县\", \"平乐镇\", \"荔浦县\", \"荔城镇\", \"龙胜各族自治县\", \"龙胜镇\", \"恭城瑶族自治县\", \"恭城镇\"] }, { name: \"柳州市\", districtAndCounty: [\"城中区\", \"鱼峰区\", \"柳南区\", \"柳北区\", \"柳江县\", \"拉堡镇\", \"柳城县\", \"大埔镇\", \"鹿寨县\", \"鹿寨镇\", \"融安县\", \"长安镇\", \"三江侗族自治县\", \"古宜镇\", \"融水苗族自治县\", \"融水镇\"] }, { name: \"梧州市\", districtAndCounty: [\"万秀区\", \"蝶山区\", \"长洲区\", \"岑溪市\", \"苍梧县\", \"龙圩镇\", \"藤县\", \"藤州镇\", \"蒙山县\", \"蒙山镇\"] }, {name: \"贵港市\", districtAndCounty: [\"港北区\", \"港南区\", \"覃塘区\", \"桂平市\", \"平南县\", \"平南镇\"]}, { name: \"玉林市\", districtAndCounty: [\"玉州区\", \"北流市\", \"兴业县\", \"石南镇\", \"容县\", \"容州镇\", \"陆川县\", \"陆城镇\", \"博白县\", \"博白镇\"] }, {name: \"钦州市\", districtAndCounty: [\"钦南区\", \"钦北区\", \"灵山县\", \"灵城镇\", \"浦北县\", \"小江镇\"]}, { name: \"北海市\", districtAndCounty: [\"海城区\", \"银海区\", \"铁山港区\", \"合浦县\", \"廉州镇\"] }, {name: \"防城港市\", districtAndCounty: [\"港口区\", \"防城区\", \"东兴市\", \"上思县\", \"思阳镇\"]}, { name: \"崇左市\", districtAndCounty: [\"江州区\", \"凭祥市\", \"扶绥县\", \"新宁镇\", \"大新县\", \"桃城镇\", \"天等县\", \"天等镇\", \"宁明县\", \"城中镇\", \"龙州县\", \"龙州镇\"] }, { name: \"百色市\", districtAndCounty: [\"右江区\", \"田阳县\", \"田州镇\", \"田东县\", \"平马镇\", \"平果县\", \"马头镇\", \"德保县\", \"城关镇\", \"靖西县\", \"新靖镇\", \"那坡县\", \"城厢镇\", \"凌云县\", \"泗城镇\", \"乐业县\", \"同乐镇\", \"西林县\", \"八达镇\", \"田林县\", \"乐里镇\", \"隆林各族自治县\", \"新州镇\"] }, { name: \"河池市\", districtAndCounty: [\"金城江区\", \"宜州市\", \"南丹县\", \"城关镇\", \"天峨县\", \"六排镇\", \"凤山县\", \"凤城镇\", \"东兰县\", \"东兰镇\", \"巴马瑶族自治县\", \"巴马镇\", \"都安瑶族自治县\", \"安阳镇\", \"大化瑶族自治县\", \"大化镇\", \"罗城仫佬族自治县\", \"东门镇\", \"环江毛南族自治县\", \"思恩镇\"] }, { name: \"来宾市\", districtAndCounty: [\"兴宾区\", \"合山市\", \"象州县\", \"象州镇\", \"武宣县\", \"武宣镇\", \"忻城县\", \"城关镇\", \"金秀瑶族自治县\", \"金秀镇\"] }, {name: \"贺州市\", districtAndCounty: [\"八步区\", \"昭平县\", \"昭平镇\", \"钟山县\", \"钟山镇\", \"富川瑶族自治县\", \"富阳镇\"]}]}, { name: \"海南省\", city: [{name: \"海口市\", districtAndCounty: [\"龙华区\", \"秀英区\", \"琼山区\", \"美兰区\"]}, { name: \"三亚市\", districtAndCounty: [] }, { name: \"省直辖行政单位\", districtAndCounty: [\"文昌市\", \"琼海市\", \"万宁市\", \"五指山市\", \"东方市\", \"儋州市\", \"临高县\", \"临城镇\", \"澄迈县\", \"金江镇\", \"定安县\", \"定城镇\", \"屯昌县\", \"屯城镇\", \"昌江黎族自治县\", \"石碌镇\", \"白沙黎族自治县\", \"牙叉镇\", \"琼中黎族苗族自治县\", \"营根镇\", \"陵水黎族自治县\", \"椰林镇\", \"保亭黎族苗族自治县\", \"保城镇\", \"乐东黎族自治县\", \"抱由镇\"] }]}, ");
            bufferedWriter.write(
                    "{ name: \"四川省\", city: [{ name: \"成都市\", districtAndCounty: [\"青羊区\", \"锦江区\", \"金牛区\", \"武侯区\", \"成华区\", \"龙泉驿区\", \"青白江区\", \"新都区\", \"温江区\", \"都江堰市\", \"彭州市\", \"邛崃市\", \"崇州市\", \"金堂县\", \"赵镇\", \"双流县\", \"郫县\", \"郫筒镇\", \"大邑县\", \"晋原镇\", \"蒲江县\", \"鹤山镇\", \"新津县\", \"五津镇\"] }, { name: \"广元市\", districtAndCounty: [\"市中区\", \"元坝区\", \"朝天区\", \"旺苍县\", \"东河镇\", \"青川县\", \"乔庄镇\", \"剑阁县\", \"下寺镇\", \"苍溪县\", \"陵江镇\"] }, { name: \"绵阳市\", districtAndCounty: [\"涪城区\", \"游仙区\", \"江油市\", \"三台县\", \"潼川镇\", \"盐亭县\", \"云溪镇\", \"安县\", \"花荄镇\", \"梓潼县\", \"文昌镇\", \"北川羌族自治县\", \"曲山镇\", \"平武县\", \"龙安镇\"] }, {name: \"德阳市\", districtAndCounty: [\"旌阳区\", \"什邡市\", \"广汉市\", \"绵竹市\", \"罗江县\", \"罗江镇\", \"中江县\", \"凯江镇\"]}, { name: \"南充市\", districtAndCounty: [\"顺庆区\", \"高坪区\", \"嘉陵区\", \"阆中市\", \"南部县\", \"南隆镇\", \"营山县\", \"朗池镇\", \"蓬安县\", \"周口镇\", \"仪陇县\", \"新政镇\", \"西充县\", \"晋城镇\"] }, {name: \"广安市\", districtAndCounty: [\"广安区\", \"华蓥市\", \"岳池县\", \"九龙镇\", \"武胜县\", \"沿口镇\", \"邻水县\", \"鼎屏镇\"]}, { name: \"遂宁市\", districtAndCounty: [\"船山区\", \"安居区\", \"蓬溪县\", \"赤城镇\", \"射洪县\", \"太和镇\", \"大英县\", \"蓬莱镇\"] }, {name: \"内江市\", districtAndCounty: [\"市中区\", \"东兴区\", \"威远县\", \"严陵镇\", \"资中县\", \"重龙镇\", \"隆昌县\", \"金鹅镇\"]}, { name: \"乐山市\", districtAndCounty: [\"市中区\", \"沙湾区\", \"五通桥区\", \"金口河区\", \"峨眉山市\", \"犍为县\", \"玉津镇\", \"井研县\", \"研城镇\", \"夹江县\", \"漹城镇\", \"沐川县\", \"沐溪镇\", \"峨边彝族自治县\", \"沙坪镇\", \"马边彝族自治县\", \"民建镇\"] }, {name: \"自贡市\", districtAndCounty: [\"自流井区\", \"大安区\", \"贡井区\", \"沿滩区\", \"荣县\", \"旭阳镇\", \"富顺县\", \"富世镇\"]}, { name: \"泸州市\", districtAndCounty: [\"江阳区\", \"纳溪区\", \"龙马潭区\", \"泸县\", \"福集镇\", \"合江县\", \"合江镇\", \"叙永县\", \"叙永镇\", \"古蔺县\", \"古蔺镇\"] }, { name: \"宜宾市\", districtAndCounty: [\"翠屏区\", \"宜宾县\", \"柏溪镇\", \"南溪县\", \"南溪镇\", \"江安县\", \"江安镇\", \"长宁县\", \"长宁镇\", \"高县\", \"庆符镇\", \"筠连县\", \"筠连镇\", \"珙县\", \"巡场镇\", \"兴文县\", \"中城镇\", \"屏山县\", \"屏山镇\"] }, {name: \"攀枝花市\", districtAndCounty: [\"东区\", \"西区\", \"仁和区\", \"米易县\", \"攀莲镇\", \"盐边县\", \"桐子林镇\"]}, { name: \"巴中市\", districtAndCounty: [\"巴州区\", \"通江县\", \"诺江镇\", \"南江县\", \"南江镇\", \"平昌县\", \"江口镇\"] }, { name: \"达州市\", districtAndCounty: [\"通川区\", \"万源市\", \"达县\", \"南外镇\", \"宣汉县\", \"东乡镇\", \"开江县\", \"新宁镇\", \"大竹县\", \"竹阳镇\", \"渠县\", \"渠江镇\"] }, {name: \"资阳市\", districtAndCounty: [\"雁江区\", \"简阳市\", \"乐至县\", \"天池镇\", \"安岳县\", \"岳阳镇\"]}, { name: \"眉山市\", districtAndCounty: [\"东坡区\", \"仁寿县\", \"文林镇\", \"彭山县\", \"凤鸣镇\", \"洪雅县\", \"洪川镇\", \"丹棱县\", \"丹棱镇\", \"青神县\", \"城厢镇\"] }, { name: \"雅安市\", districtAndCounty: [\"雨城区\", \"名山县\", \"蒙阳镇\", \"荥经县\", \"严道镇\", \"汉源县\", \"富林镇\", \"石棉县\", \"新棉镇\", \"天全县\", \"城厢镇\", \"芦山县\", \"芦阳镇\", \"宝兴县\", \"穆坪镇\"] }, { name: \"阿坝州\", districtAndCounty: [\"马尔康县\", \"马尔康镇\", \"汶川县\", \"威州镇\", \"理县\", \"杂谷脑镇\", \"茂县\", \"凤仪镇\", \"松潘县\", \"进安镇\", \"九寨沟县\", \"永乐镇\", \"金川县\", \"金川镇\", \"小金县\", \"美兴镇\", \"黑水县\", \"芦花镇\", \"壤塘县\", \"壤柯镇\", \"阿坝县\", \"阿坝镇\", \"若尔盖县\", \"达扎寺镇\", \"红原县\", \"邛溪镇\"] }, { name: \"甘孜州\", districtAndCounty: [\"康定县\", \"炉城镇\", \"泸定县\", \"泸桥镇\", \"丹巴县\", \"章谷镇\", \"九龙县\", \"呷尔镇\", \"雅江县\", \"河口镇\", \"道孚县\", \"鲜水镇\", \"炉霍县\", \"新都镇\", \"甘孜县\", \"甘孜镇\", \"新龙县\", \"茹龙镇\", \"德格县\", \"更庆镇\", \"白玉县\", \"建设镇\", \"石渠县\", \"尼呷镇\", \"色达县\", \"色柯镇\", \"理塘县\", \"高城镇\", \"巴塘县\", \"夏邛镇\", \"乡城县\", \"桑披镇\", \"稻城县\", \"金珠镇\", \"得荣县\", \"松麦镇\"] }, { name: \"凉山州\", districtAndCounty: [\"西昌市\", \"盐源县\", \"盐井镇\", \"德昌县\", \"德州镇\", \"会理县\", \"城关镇\", \"会东县\", \"会东镇\", \"宁南县\", \"披砂镇\", \"普格县\", \"普基镇\", \"布拖县\", \"特木里镇\", \"金阳县\", \"天地坝镇\", \"昭觉县\", \"新城镇\", \"喜德县\", \"光明镇\", \"冕宁县\", \"城厢镇\", \"越西县\", \"越城镇\", \"甘洛县\", \"新市坝镇\", \"美姑县\", \"巴普镇\", \"雷波县\", \"锦城镇\", \"木里藏族自治县\", \"乔瓦镇\"] }]}, { name: \"贵州省\", city: [{ name: \"贵阳市\", districtAndCounty: [\"乌当区\", \"南明区\", \"云岩区\", \"花溪区\", \"白云区\", \"小河区\", \"清镇市\", \"开阳县\", \"城关镇\", \"修文县\", \"龙场镇\", \"息烽县\", \"永靖镇\"] }, {name: \"六盘水市\", districtAndCounty: [\"钟山区\", \"盘县\", \"红果镇\", \"六枝特区\", \"平寨镇\", \"水城县\"]}, { name: \"遵义市\", districtAndCounty: [\"红花岗区\", \"汇川区\", \"赤水市\", \"仁怀市\", \"遵义县\", \"南白镇\", \"桐梓县\", \"娄山关镇\", \"绥阳县\", \"洋川镇\", \"正安县\", \"凤仪镇\", \"凤冈县\", \"龙泉镇\", \"湄潭县\", \"湄江镇\", \"余庆县\", \"白泥镇\", \"习水县\", \"东皇镇\", \"道真仡佬族苗族自治县\", \"玉溪镇\", \"务川仡佬族苗族自治县\", \"都濡镇\"] }, { name: \"安顺市\", districtAndCounty: [\"西秀区\", \"平坝县\", \"城关镇\", \"普定县\", \"城关镇\", \"关岭布依族苗族自治县\", \"关索镇\", \"镇宁布依族苗族自治县\", \"城关镇\", \"紫云苗族布依族自治县\", \"松山镇\"] }, { name: \"毕节地区\", districtAndCounty: [\"毕节市\", \"大方县\", \"大方镇\", \"黔西县\", \"城关镇\", \"金沙县\", \"城关镇\", \"织金县\", \"城关镇\", \"纳雍县\", \"雍熙镇\", \"赫章县\", \"城关镇\", \"威宁彝族回族苗族自治县\", \"草海镇\"] }, { name: \"铜仁地区\", districtAndCounty: [\"铜仁市\", \"江口县\", \"双江镇\", \"石阡县\", \"汤山镇\", \"思南县\", \"思唐镇\", \"德江县\", \"青龙镇\", \"玉屏侗族自治县\", \"平溪镇\", \"印江土家族苗族自治县\", \"峨岭镇\", \"沿河土家族自治县\", \"和平镇\", \"松桃苗族自治县\", \"蓼皋镇\", \"万山特区\", \"万山镇\"] }, { name: \"黔东南州\", districtAndCounty: [\"凯里市\", \"黄平县\", \"新州镇\", \"施秉县\", \"城关镇\", \"三穗县\", \"八弓镇\", \"镇远县\", \"阳镇\", \"岑巩县\", \"思旸镇\", \"天柱县\", \"凤城镇\", \"锦屏县\", \"三江镇\", \"剑河县\", \"革东镇\", \"台江县\", \"台拱镇\", \"黎平县\", \"德凤镇\", \"榕江县\", \"古州镇\", \"从江县\", \"丙妹镇\", \"雷山县\", \"丹江镇\", \"麻江县\", \"杏山镇\", \"丹寨县\", \"龙泉镇\"] }, { name: \"黔南州\", districtAndCounty: [\"都匀市\", \"福泉市\", \"荔波县\", \"玉屏镇\", \"贵定县\", \"城关镇\", \"瓮安县\", \"雍阳镇\", \"独山县\", \"城关镇\", \"平塘县\", \"平湖镇\", \"罗甸县\", \"龙坪镇\", \"长顺县\", \"长寨镇\", \"龙里县\", \"龙山镇\", \"惠水县\", \"和平镇\", \"三都水族自治县\", \"三合镇\"] }, { name: \"黔西南州\", districtAndCounty: [\"兴义市\", \"兴仁县\", \"城关镇\", \"普安县\", \"盘水镇\", \"晴隆县\", \"莲城镇\", \"贞丰县\", \"珉谷镇\", \"望谟县\", \"复兴镇\", \"册亨县\", \"者楼镇\", \"安龙县\", \"新安镇\"] }]}, { name: \"云南省\", city: [{ name: \"昆明市\", districtAndCounty: [\"盘龙区\", \"五华区\", \"官渡区\", \"西山区\", \"东川区\", \"安宁市\", \"呈贡县\", \"龙城镇\", \"晋宁县\", \"昆阳镇\", \"富民县\", \"永定镇\", \"宜良县\", \"匡远镇\", \"嵩明县\", \"嵩阳镇\", \"石林彝族自治县\", \"鹿阜镇\", \"禄劝彝族苗族自治县\", \"屏山镇\", \"寻甸回族彝族自治县\", \"仁德镇\"] }, { name: \"曲靖市\", districtAndCounty: [\"麒麟区\", \"宣威市\", \"马龙县\", \"通泉镇\", \"沾益县\", \"西平镇\", \"富源县\", \"中安镇\", \"罗平县\", \"罗雄镇\", \"师宗县\", \"丹凤镇\", \"陆良县\", \"中枢镇\", \"会泽县\", \"金钟镇\"] }, { name: \"玉溪市\", districtAndCounty: [\"红塔区\", \"江川县\", \"大街镇\", \"澄江县\", \"凤麓镇\", \"通海县\", \"秀山镇\", \"华宁县\", \"宁州镇\", \"易门县\", \"龙泉镇\", \"峨山彝族自治县\", \"双江镇\", \"新平彝族傣族自治县\", \"桂山镇\", \"元江哈尼族彝族傣族自治县\", \"澧江镇\"] }, {name: \"保山市\", districtAndCounty: [\"隆阳区\", \"施甸县\", \"甸阳镇\", \"腾冲县\", \"腾越镇\", \"龙陵县\", \"龙山镇\", \"昌宁县\", \"田园镇\"]}, { name: \"昭通市\", districtAndCounty: [\"昭阳区\", \"鲁甸县\", \"文屏镇\", \"巧家县\", \"新华镇\", \"盐津县\", \"盐井镇\", \"大关县\", \"翠华镇\", \"永善县\", \"溪落渡镇\", \"绥江县\", \"中城镇\", \"镇雄县\", \"乌峰镇\", \"彝良县\", \"角奎镇\", \"威信县\", \"扎西镇\", \"水富县\", \"向家坝镇\"] }, { name: \"丽江市\", districtAndCounty: [\"古城区\", \"永胜县\", \"永北镇\", \"华坪县\", \"中心镇\", \"玉龙纳西族自治县\", \"黄山镇\", \"宁蒗彝族自治县\", \"大兴镇\"] }, { name: \"思茅市\", districtAndCounty: [\"翠云区\", \"普洱哈尼族彝族自治县\", \"宁洱镇\", \"墨江哈尼族自治县\", \"联珠镇\", \"景东彝族自治县\", \"锦屏镇\", \"景谷傣族彝族自治县\", \"威远镇\", \"镇沅彝族哈尼族拉祜族自治县\", \"恩乐镇\", \"江城哈尼族彝族自治县\", \"勐烈镇\", \"孟连傣族拉祜族佤族自治县\", \"娜允镇\", \"澜沧拉祜族自治县\", \"勐朗镇\", \"西盟佤族自治县\", \"勐梭镇\"] }, { name: \"临沧市\", districtAndCounty: [\"临翔区\", \"凤庆县\", \"凤山镇\", \"云县\", \"爱华镇\", \"永德县\", \"德党镇\", \"镇康县\", \"南伞镇\", \"双江拉祜族佤族布朗族傣族自治县\", \"勐勐镇\", \"耿马傣族佤族自治县\", \"耿马镇\", \"沧源佤族自治县\", \"勐董镇\"] }, {name: \"德宏州\", districtAndCounty: [\"潞西市\", \"瑞丽市\", \"梁河县\", \"遮岛镇\", \"盈江县\", \"平原镇\", \"陇川县\", \"章凤镇\"]}, { name: \"怒江州\", districtAndCounty: [\"泸水县六库镇\", \"泸水县\", \"六库镇\", \"福贡县\", \"上帕镇\", \"贡山独龙族怒族自治县\", \"茨开镇\", \"兰坪白族普米族自治县\", \"金顶镇\"] }, {name: \"迪庆州\", districtAndCounty: [\"香格里拉县\", \"建塘镇\", \"德钦县\", \"升平镇\", \"维西傈僳族自治县\", \"保和镇\"]}, { name: \"大理州\", districtAndCounty: [\"大理市\", \"祥云县\", \"祥城镇\", \"宾川县\", \"金牛镇\", \"弥渡县\", \"弥城镇\", \"永平县\", \"博南镇\", \"云龙县\", \"诺邓镇\", \"洱源县\", \"茈碧湖镇\", \"剑川县\", \"金华镇\", \"鹤庆县\", \"云鹤镇\", \"漾濞彝族自治县\", \"苍山西镇\", \"南涧彝族自治县\", \"南涧镇\", \"巍山彝族回族自治县\", \"南诏镇\"] }, { name: \"楚雄州\", districtAndCounty: [\"楚雄市\", \"双柏县\", \"妥甸镇\", \"牟定县\", \"共和镇\", \"南华县\", \"龙川镇\", \"姚安县\", \"栋川镇\", \"大姚县\", \"金碧镇\", \"永仁县\", \"永定镇\", \"元谋县\", \"元马镇\", \"武定县\", \"狮山镇\", \"禄丰县\", \"金山镇\"] }, { name: \"红河州\", districtAndCounty: [\"蒙自县\", \"文澜镇\", \"个旧市\", \"开远市\", \"绿春县\", \"大兴镇\", \"建水县\", \"临安镇\", \"石屏县\", \"异龙镇\", \"弥勒县\", \"弥阳镇\", \"泸西县\", \"中枢镇\", \"元阳县\", \"南沙镇\", \"红河县\", \"迤萨镇\", \"金平苗族瑶族傣族自治县\", \"金河镇\", \"河口瑶族自治县\", \"河口镇\", \"屏边苗族自治县\", \"玉屏镇\"] }, { name: \"文山州\", districtAndCounty: [\"文山县\", \"开化镇\", \"砚山县\", \"江那镇\", \"西畴县\", \"西洒镇\", \"麻栗坡县\", \"麻栗镇\", \"马关县\", \"马白镇\", \"丘北县\", \"锦屏镇\", \"广南县\", \"莲城镇\", \"富宁县\", \"新华镇\"] }, {name: \"西双版纳州\", districtAndCounty: [\"景洪市\", \"勐海县\", \"勐海镇\", \"勐腊县\", \"勐腊镇\"]}]}, { name: \"西藏\", city: [{ name: \"拉萨市\", districtAndCounty: [\"城关区\", \"林周县\", \"甘丹曲果镇\", \"当雄县\", \"当曲卡镇\", \"尼木县\", \"塔荣镇\", \"曲水县\", \"曲水镇\", \"堆龙德庆县\", \"东嘎镇\", \"达孜县\", \"德庆镇\", \"墨竹工卡县\", \"工卡镇\"] }, { name: \"那曲地区\", districtAndCounty: [\"那曲县\", \"那曲镇\", \"嘉黎县\", \"阿扎镇\", \"比如县\", \"比如镇\", \"聂荣县\", \"聂荣镇\", \"安多县\", \"帕那镇\", \"申扎县\", \"申扎镇\", \"索县\", \"亚拉镇\", \"班戈县\", \"普保镇\", \"巴青县\", \"拉西镇\", \"尼玛县\", \"尼玛镇\"] }, { name: \"昌都地区\", districtAndCounty: [\"昌都县\", \"城关镇\", \"江达县\", \"江达镇\", \"贡觉县\", \"莫洛镇\", \"类乌齐县\", \"桑多镇\", \"丁青县\", \"丁青镇\", \"察雅县\", \"烟多镇\", \"八宿县\", \"白玛镇\", \"左贡县\", \"旺达镇\", \"芒康县\", \"嘎托镇\", \"洛隆县\", \"孜托镇\", \"边坝县\", \"草卡镇\"] }, { name: \"林芝地区\", districtAndCounty: [\"林芝县\", \"八一镇\", \"工布江达县\", \"工布江达镇\", \"米林县\", \"米林镇\", \"墨脱县\", \"墨脱镇\", \"波密县\", \"扎木镇\", \"察隅县\", \"竹瓦根镇\", \"朗县\", \"朗镇\"] }, { name: \"山南地区\", districtAndCounty: [\"乃东县\", \"泽当镇\", \"扎囊县\", \"扎塘镇\", \"贡嘎县\", \"吉雄镇\", \"桑日县\", \"桑日镇\", \"琼结县\", \"琼结镇\", \"曲松县\", \"曲松镇\", \"措美县\", \"措美镇\", \"洛扎县\", \"洛扎镇\", \"加查县\", \"安绕镇\", \"隆子县\", \"隆子镇\", \"错那县\", \"错那镇\", \"浪卡子县\", \"浪卡子镇\"] }, { name: \"日喀则地区\", districtAndCounty: [\"日喀则市\", \"南木林县\", \"南木林镇\", \"江孜县\", \"江孜镇\", \"定日县\", \"协格尔镇\", \"萨迦县\", \"萨迦镇\", \"拉孜县\", \"曲下镇\", \"昂仁县\", \"卡嘎镇\", \"谢通门县\", \"卡嘎镇\", \"白朗县\", \"洛江镇\", \"仁布县\", \"德吉林镇\", \"康马县\", \"康马镇\", \"定结县\", \"江嘎镇\", \"仲巴县\", \"拉让乡\", \"亚东县\", \"下司马镇\", \"吉隆县\", \"宗嘎镇\", \"聂拉木县\", \"聂拉木镇\", \"萨嘎县\", \"加加镇\", \"岗巴县\", \"岗巴镇\"] }, { name: \"阿里地区\", districtAndCounty: [\"噶尔县\", \"狮泉河镇\", \"普兰县\", \"普兰镇\", \"札达县\", \"托林镇\", \"日土县\", \"日土镇\", \"革吉县\", \"革吉镇\", \"改则县\", \"改则镇\", \"措勤县\", \"措勤镇\", \"林芝县人民政府驻地由林芝镇迁至八一镇\"] }]}, { name: \"陕西省\", city: [{ name: \"西安市\", districtAndCounty: [\"莲湖区\", \"新城区\", \"碑林区\", \"灞桥区\", \"未央区\", \"雁塔区\", \"阎良区\", \"临潼区\", \"长安区\", \"蓝田县\", \"蓝关镇\", \"周至县\", \"二曲镇\", \"户县\", \"甘亭镇\", \"高陵县\", \"鹿苑镇\"] }, { name: \"延安市\", districtAndCounty: [\"宝塔区\", \"延长县\", \"七里村镇\", \"延川县\", \"延川镇\", \"子长县\", \"瓦窑堡镇\", \"安塞县\", \"真武洞镇\", \"志丹县\", \"保安镇\", \"吴起县\", \"吴旗镇\", \"甘泉县\", \"城关镇\", \"富县\", \"富城镇\", \"洛川县\", \"凤栖镇\", \"宜川县\", \"丹州镇\", \"黄龙县\", \"石堡镇\", \"黄陵县\", \"桥山镇\"] }, {name: \"铜川市\", districtAndCounty: [\"耀州区\", \"王益区\", \"印台区\", \"宜君县\", \"城关镇\"]}, { name: \"渭南市\", districtAndCounty: [\"临渭区\", \"华阴市\", \"韩城市\", \"华县\", \"华州镇\", \"潼关县\", \"城关镇\", \"大荔县\", \"城关镇\", \"蒲城县\", \"城关镇\", \"澄城县\", \"城关镇\", \"白水县\", \"城关镇\", \"合阳县\", \"城关镇\", \"富平县\", \"窦村镇\"] }, { name: \"咸阳市\", districtAndCounty: [\"秦都区\", \"杨陵区\", \"渭城区\", \"兴平市\", \"三原县\", \"城关镇\", \"泾阳县\", \"泾干镇\", \"乾县\", \"城关镇\", \"礼泉县\", \"城关镇\", \"永寿县\", \"监军镇\", \"彬县\", \"城关镇\", \"长武县\", \"昭仁镇\", \"旬邑县\", \"城关镇\", \"淳化县\", \"城关镇\", \"武功县\", \"普集镇\"] }, { name: \"宝鸡市\", districtAndCounty: [\"渭滨区\", \"金台区\", \"陈仓区\", \"凤翔县\", \"城关镇\", \"岐山县\", \"凤鸣镇\", \"扶风县\", \"城关镇\", \"眉县\", \"首善镇\", \"陇县\", \"城关镇\", \"千阳县\", \"城关镇\", \"麟游县\", \"九成宫镇\", \"凤县\", \"双石铺镇\", \"太白县\", \"嘴头镇\"] }, { name: \"汉中市\", districtAndCounty: [\"汉台区\", \"南郑县\", \"城关镇\", \"城固县\", \"博望镇\", \"洋县\", \"洋州镇\", \"西乡县\", \"城关镇\", \"勉县\", \"勉阳镇\", \"宁强县\", \"汉源镇\", \"略阳县\", \"城关镇\", \"镇巴县\", \"泾洋镇\", \"留坝县\", \"城关镇\", \"佛坪县\", \"袁家庄镇\"] }, { name: \"榆林市\", districtAndCounty: [\"榆阳区\", \"神木县\", \"神木镇\", \"府谷县\", \"府谷镇\", \"横山县\", \"横山镇\", \"靖边县\", \"张家畔镇\", \"定边县\", \"定边镇\", \"绥德县\", \"名州镇\", \"米脂县\", \"银州镇\", \"佳县\", \"佳芦镇\", \"吴堡县\", \"宋家川镇\", \"清涧县\", \"宽洲镇\", \"子洲县\", \"双湖峪镇\"] }, { name: \"安康市\", districtAndCounty: [\"汉滨区\", \"汉阴县\", \"城关镇\", \"石泉县\", \"城关镇\", \"宁陕县\", \"城关镇\", \"紫阳县\", \"城关镇\", \"岚皋县\", \"城关镇\", \"平利县\", \"城关镇\", \"镇坪县\", \"城关镇\", \"旬阳县\", \"城关镇\", \"白河县\", \"城关镇\"] }, { name: \"商洛市\", districtAndCounty: [\"商州区\", \"洛南县\", \"城关镇\", \"丹凤县\", \"龙驹寨镇\", \"商南县\", \"城关镇\", \"山阳县\", \"城关镇\", \"镇安县\", \"永乐镇\", \"柞水县\", \"乾佑镇\"] }]}, { name: \"甘肃省\", city: [{ name: \"兰州市\", districtAndCounty: [\"城关区\", \"七里河区\", \"西固区\", \"安宁区\", \"红古区\", \"永登县\", \"城关镇\", \"皋兰县\", \"石洞镇\", \"榆中县\", \"城关镇\"] }, {name: \"嘉峪关市\", districtAndCounty: [\"金昌市\", \"金川区\", \"永昌县\", \"城关镇\"]}, { name: \"白银市\", districtAndCounty: [\"白银区\", \"平川区\", \"靖远县\", \"乌兰镇\", \"会宁县\", \"会师镇\", \"景泰县\", \"一条山镇\"] }, { name: \"天水市\", districtAndCounty: [\"秦州区\", \"麦积区\", \"清水县\", \"永清镇\", \"秦安县\", \"兴国镇\", \"甘谷县\", \"大像山镇\", \"武山县\", \"城关镇\", \"张家川回族自治县\", \"张家川镇\"] }, {name: \"武威市\", districtAndCounty: [\"凉州区\", \"民勤县\", \"城关镇\", \"古浪县\", \"古浪镇\", \"天祝藏族自治县\", \"华藏寺镇\"]}, { name: \"酒泉市\", districtAndCounty: [\"肃州区\", \"玉门市\", \"敦煌市\", \"金塔县\", \"金塔镇\", \"安西县\", \"渊泉镇\", \"肃北蒙古族自治县\", \"党城湾镇\", \"阿克塞哈萨克族自治县\", \"红柳湾镇\"] }, { name: \"张掖市\", districtAndCounty: [\"甘州区\", \"民乐县\", \"洪水镇\", \"临泽县\", \"沙河镇\", \"高台县\", \"城关镇\", \"山丹县\", \"清泉镇\", \"肃南裕固族自治县\", \"红湾寺镇\"] }, { name: \"庆阳市\", districtAndCounty: [\"西峰区\", \"庆城县\", \"庆城镇\", \"环县\", \"环城镇\", \"华池县\", \"柔远镇\", \"合水县\", \"西华池镇\", \"正宁县\", \"山河镇\", \"宁县\", \"新宁镇\", \"镇原县\", \"城关镇\"] }, { name: \"平凉市\", districtAndCounty: [\"崆峒区\", \"泾川县\", \"城关镇\", \"灵台县\", \"中台镇\", \"崇信县\", \"锦屏镇\", \"华亭县\", \"东华镇\", \"庄浪县\", \"水洛镇\", \"静宁县\", \"城关镇\"] }, { name: \"定西市\", districtAndCounty: [\"安定区\", \"通渭县\", \"平襄镇\", \"临洮县\", \"洮阳镇\", \"漳县\", \"武阳镇\", \"岷县\", \"岷阳镇\", \"渭源县\", \"清源镇\", \"陇西县\", \"巩昌镇\"] }, { name: \"陇南市\", districtAndCounty: [\"武都区\", \"成县\", \"城关镇\", \"宕昌县\", \"城关镇\", \"康县\", \"文县\", \"城关镇\", \"西和县\", \"汉源镇\", \"礼县\", \"城关镇\", \"两当县\", \"城关镇\", \"徽县\", \"城关镇\"] }, { name: \"临夏州\", districtAndCounty: [\"临夏市\", \"临夏县\", \"韩集镇\", \"康乐县\", \"附城镇\", \"永靖县\", \"刘家峡镇\", \"广河县\", \"城关镇\", \"和政县\", \"城关镇\", \"东乡族自治县\", \"锁南坝镇\", \"积石山保安族东乡族撒拉族自治县\", \"吹麻滩镇\"] }, { name: \"甘南州\", districtAndCounty: [\"合作市\", \"临潭县\", \"城关镇\", \"卓尼县\", \"柳林镇\", \"舟曲县\", \"城关镇\", \"迭部县\", \"电尕镇\", \"玛曲县\", \"尼玛镇\", \"碌曲县\", \"玛艾镇\", \"夏河县\", \"拉卜楞镇\"] }]}, { name: \"青海省\", city: [{ name: \"西宁市\", districtAndCounty: [\"城中区\", \"城东区\", \"城西区\", \"城北区\", \"大通回族土族自治县\", \"桥头镇\", \"湟源县\", \"城关镇\", \"湟中县\", \"鲁沙尔镇\"] }, { name: \"海东地区\", districtAndCounty: [\"平安县\", \"平安镇\", \"乐都县\", \"碾伯镇\", \"民和回族土族自治县\", \"川口镇\", \"互助土族自治县\", \"威远镇\", \"化隆回族自治县\", \"巴燕镇\", \"循化撒拉族自治县\", \"积石镇\"] }, {name: \"海北州\", districtAndCounty: [\"海晏县\", \"三角城镇\", \"祁连县\", \"八宝镇\", \"刚察县\", \"沙柳河镇\", \"门源回族自治县\", \"浩门镇\"]}, { name: \"海南州\", districtAndCounty: [\"共和县\", \"恰卜恰镇\", \"同德县\", \"尕巴松多镇\", \"贵德县\", \"河阴镇\", \"兴海县\", \"子科滩镇\", \"贵南县\", \"茫曲镇\"] }, {name: \"黄南州\", districtAndCounty: [\"同仁县\", \"隆务镇\", \"尖扎县\", \"马克唐镇\", \"泽库县\", \"泽曲镇\", \"河南蒙古族自治县\", \"优干宁镇\"]}, { name: \"果洛州\", districtAndCounty: [\"玛沁县\", \"大武镇\", \"班玛县\", \"赛来塘镇\", \"甘德县\", \"柯曲镇\", \"达日县\", \"吉迈镇\", \"久治县\", \"智青松多镇\", \"玛多县\", \"黄河乡\"] }, { name: \"玉树州\", districtAndCounty: [\"玉树县\", \"结古镇\", \"杂多县\", \"萨呼腾镇\", \"称多县\", \"称文镇\", \"治多县\", \"加吉博洛镇\", \"囊谦县\", \"香达镇\", \"曲麻莱县\", \"约改镇\"] }, {name: \"海西州\", districtAndCounty: [\"德令哈市\", \"格尔木市\", \"乌兰县\", \"希里沟镇\", \"都兰县\", \"察汗乌苏镇\", \"天峻县\", \"新源镇\"]}]}, { name: \"宁夏\", city: [{name: \"银川市\", districtAndCounty: [\"兴庆区\", \"金凤区\", \"西夏区\", \"灵武市\", \"永宁县\", \"杨和镇\", \"贺兰县\", \"习岗镇\"]}, { name: \"石嘴山市\", districtAndCounty: [\"大武口区\", \"惠农区\", \"平罗县\", \"城关镇\"] }, {name: \"吴忠市\", districtAndCounty: [\"利通区\", \"青铜峡市\", \"盐池县\", \"花马池镇\", \"同心县\", \"豫海镇\"]}, { name: \"固原市\", districtAndCounty: [\"原州区\", \"西吉县\", \"吉强镇\", \"隆德县\", \"城关镇\", \"泾源县\", \"香水镇\", \"彭阳县\", \"白阳镇\"] }, {name: \"中卫市\", districtAndCounty: [\"沙坡头区\", \"中宁县\", \"海原县\"]}]}, { name: \"新疆\", city: [{ name: \"乌鲁木齐市\", districtAndCounty: [\"天山区\", \"沙依巴克区\", \"新市区\", \"水磨沟区\", \"头屯河区\", \"达坂城区\", \"东山区\", \"乌鲁木齐县\", \"乌鲁木齐市水磨沟区\"] }, {name: \"克拉玛依市\", districtAndCounty: [\"克拉玛依区\", \"独山子区\", \"白碱滩区\", \"乌尔禾区\"]}, { name: \"自治区直辖县级行政单位\", districtAndCounty: [\"石河子市\", \"阿拉尔市\", \"图木舒克市\", \"五家渠市\"] }, { name: \"喀什地区\", districtAndCounty: [\"喀什市\", \"疏附县\", \"托克扎克镇\", \"疏勒县\", \"疏勒镇\", \"英吉沙县\", \"英吉沙镇\", \"泽普县\", \"泽普镇\", \"莎车县\", \"莎车镇\", \"叶城县\", \"喀格勒克镇\", \"麦盖提县\", \"麦盖提镇\", \"岳普湖县\", \"岳普湖镇\", \"伽师县\", \"巴仁镇\", \"巴楚县\", \"巴楚镇\", \"塔什库尔干塔吉克自治县\", \"塔什库尔干镇\"] }, { name: \"阿克苏地区\", districtAndCounty: [\"阿克苏市\", \"温宿县\", \"温宿镇\", \"库车县\", \"库车镇\", \"沙雅县\", \"沙雅镇\", \"新和县\", \"新和镇\", \"拜城县\", \"拜城镇\", \"乌什县\", \"乌什镇\", \"阿瓦提县\", \"阿瓦提镇\", \"柯坪县\", \"柯坪镇\"] }, { name: \"和田地区\", districtAndCounty: [\"和田市\", \"和田县\", \"墨玉县\", \"喀拉喀什镇\", \"皮山县\", \"固玛镇\", \"洛浦县\", \"洛浦镇\", \"策勒县\", \"策勒镇\", \"于田县\", \"木尕拉镇\", \"民丰县\", \"尼雅镇\"] }, {name: \"吐鲁番地区\", districtAndCounty: [\"吐鲁番市\", \"鄯善县\", \"鄯善镇\", \"托克逊县\", \"托克逊镇\"]}, { name: \"哈密地区\", districtAndCounty: [\"哈密市\", \"伊吾县\", \"伊吾镇\", \"巴里坤哈萨克自治县\", \"巴里坤镇\"] }, {name: \"克孜勒苏柯州\", districtAndCounty: [\"阿图什市\", \"阿克陶县\", \"阿克陶镇\", \"阿合奇县\", \"阿合奇镇\", \"乌恰县\", \"乌恰镇\"]}, { name: \"博尔塔拉州\", districtAndCounty: [\"博乐市\", \"精河县\", \"精河镇\", \"温泉县\", \"博格达尔镇\"] }, { name: \"昌吉州\", districtAndCounty: [\"昌吉市\", \"阜康市\", \"米泉市\", \"呼图壁县\", \"呼图壁镇\", \"玛纳斯县\", \"玛纳斯镇\", \"奇台县\", \"奇台镇\", \"吉木萨尔县\", \"吉木萨尔镇\", \"木垒哈萨克自治县\", \"木垒镇\"] }, { name: \"巴音郭楞州\", districtAndCounty: [\"库尔勒市\", \"轮台县\", \"轮台镇\", \"尉犁县\", \"尉犁镇\", \"若羌县\", \"若羌镇\", \"且末县\", \"且末镇\", \"和静县\", \"和静镇\", \"和硕县\", \"特吾里克镇\", \"博湖县\", \"博湖镇\", \"焉耆回族自治县\", \"焉耆镇\"] }, { name: \"伊犁州\", districtAndCounty: [\"伊宁市\", \"奎屯市\", \"伊宁县\", \"吉里于孜镇\", \"霍城县\", \"水定镇\", \"巩留县\", \"巩留镇\", \"新源县\", \"新源镇\", \"昭苏县\", \"昭苏镇\", \"特克斯县\", \"特克斯镇\", \"尼勒克县\", \"尼勒克镇\", \"察布查尔锡伯自治县\", \"察布查尔镇\"] }, { name: \"塔城地区\", districtAndCounty: [\"塔城市\", \"乌苏市\", \"额敏县\", \"额敏镇\", \"沙湾县\", \"三道河子镇\", \"托里县\", \"托里镇\", \"裕民县\", \"哈拉布拉镇\", \"和布克赛尔蒙古自治县\", \"和布克赛尔镇\"] }, {name: \"阿勒泰地区\", districtAndCounty: [\"阿勒泰市\", \"布尔津县\", \"布尔津镇\", \"富蕴县\", \"库额尔齐斯镇\", \"福海县\", \"哈巴河县\", \"青河县\", \"吉木乃县\"]}]}, { name: \"香港\", city: [{ name: \"香港特别行政区\", districtAndCounty: [\"中西区\", \"东区\", \"九龙城区\", \"观塘区\", \"南区\", \"深水埗区\", \"湾仔区\", \"黄大仙区\", \"油尖旺区\", \"离岛区\", \"葵青区\", \"北区\", \"西贡区\", \"沙田区\", \"屯门区\", \"大埔区\", \"荃湾区\", \"元朗区\"] }]}, {name: \"澳门\", city: [{name: \"澳门特别行政区\", districtAndCounty: [\"澳门特别行政区\"]}]}, { name: \"台湾省\", city: [{name: \"台北\", districtAndCounty: []}, {name: \"高雄\", districtAndCounty: []}, { name: \"台中\", districtAndCounty: [] }, {name: \"花莲\", districtAndCounty: []}, {name: \"基隆\", districtAndCounty: []}, { name: \"嘉义\", districtAndCounty: [] }, {name: \"金门\", districtAndCounty: []}, {name: \"连江\", districtAndCounty: []}, { name: \"苗栗\", districtAndCounty: [] }, {name: \"南投\", districtAndCounty: []}, {name: \"澎湖\", districtAndCounty: []}, { name: \"屏东\", districtAndCounty: [] }, {name: \"台东\", districtAndCounty: []}, {name: \"台南\", districtAndCounty: []}, { name: \"桃园\", districtAndCounty: [] }, {name: \"新竹\", districtAndCounty: []}, {name: \"宜兰\", districtAndCounty: []}, { name: \"云林\", districtAndCounty: [] }, {name: \"彰化\", districtAndCounty: []}]}];\n" +
                            "\n" +
                            "/*用于保存当前所选的省市区*/\n" +
                            "var current = {\n" +
                            "    prov: '',\n" +
                            "    city: '',\n" +
                            "    country: ''\n" +
                            "};\n" +
                            "\n" +
                            "/*自动加载省份列表*/\n" +
                            "var showProv = function(provinceId) {\n" +
                            "    var prov = document.getElementById(provinceId);\n" +
                            "    var len = province.length;\n" +
                            "    for (var i = 0; i < len; i++) {\n" +
                            "        var provOpt = document.createElement('option');\n" +
                            "        provOpt.innerText = province[i]['name'];\n" +
                            "        provOpt.value = i;\n" +
                            "        prov.appendChild(provOpt);\n" +
                            "    }\n" +
                            "}\n" +
                            "\n" +
                            "/*根据所选的省份来显示城市列表*/\n" +
                            "var showCity = function(obj, provinceId, cityId) {\n" +
                            "    var prov = document.getElementById(provinceId);\n" +
                            "    var city = document.getElementById(cityId);\n" +
                            "    var val = obj.options[obj.selectedIndex].value;\n" +
                            "    if (val != current.prov) {\n" +
                            "        current.prov = val;\n" +
                            "    }\n" +
                            "    if (val != null && val != \"\") {\n" +
                            "        city.length = 1;\n" +
                            "        var cityLen = province[val][\"city\"].length;\n" +
                            "        for (var j = 0; j < cityLen; j++) {\n" +
                            "            var cityOpt = document.createElement('option');\n" +
                            "            cityOpt.innerText = province[val][\"city\"][j].name;\n" +
                            "            cityOpt.value = j;\n" +
                            "            city.appendChild(cityOpt);\n" +
                            "        }\n" +
                            "    }\n" +
                            "}\n" +
                            "\n" +
                            "/*根据所选的城市来显示县区列表*/\n" +
                            "var showArea = function(obj,provinceId, cityId, areaId) {\n" +
                            "    var prov = document.getElementById(provinceId);\n" +
                            "    var city = document.getElementById(cityId);\n" +
                            "    var area = document.getElementById(areaId);\n" +
                            "    var val = obj.options[obj.selectedIndex].value;\n" +
                            "    current.city = val;\n" +
                            "    if (val != null) {\n" +
                            "        area.length = 1; //清空之前的内容只留第一个默认选项\n" +
                            "        var countryLen = province[current.prov][\"city\"][val].districtAndCounty.length;\n" +
                            "        if (countryLen == 0) {\n" +
                            "            return;\n" +
                            "        }\n" +
                            "        for (var k = 0; k < countryLen; k++) {\n" +
                            "            var countryOpt = document.createElement('option');\n" +
                            "            countryOpt.innerText = province[current.prov][\"city\"][val].districtAndCounty[k];\n" +
                            "            countryOpt.value = k;\n" +
                            "            area.appendChild(countryOpt);\n" +
                            "        }\n" +
                            "    }\n" +
                            "}\n");
            System.out.println("write to file success : " + file.getPath());
        } catch (IOException e) {
            e.printStackTrace();
        } finally {
            MybatisUtilCommon.closeBufferWriterAndFileOutputStream(fileOutputStream, bufferedWriter);
        }
    }

    public static void writeCommonPageShareJsCommonTablesColumnsJs(String htmlPath, String serverUrl) {
        File file = null;
        OutputStream fileOutputStream = null;
        BufferedWriter bufferedWriter = null;
        try {
            File folder = new File(htmlPath + "/common/page-share/js");
            folder.mkdirs();
            file = new File(htmlPath + "/common/page-share/js/common-tables-columns.js");
            //如果文件不存在，则创建文件，如果已存在，则覆盖
            file.createNewFile();
            fileOutputStream = new FileOutputStream(file);
            bufferedWriter = new BufferedWriter(new OutputStreamWriter(fileOutputStream, "utf-8"));
            List<Map> fileList = MybatisUtilCommon.getFileListFromConfigFile();
            bufferedWriter.write("var tablesColumns=" + JSON.toJSONString(fileList));
            System.out.println("write to file success : " + file.getPath());
        } catch (IOException e) {
            e.printStackTrace();
        } finally {
            MybatisUtilCommon.closeBufferWriterAndFileOutputStream(fileOutputStream, bufferedWriter);
        }
    }

    public static void writeCustomPageCustomJsCustomFunctionJs(String htmlPath, String serverUrl) {
        File file = null;
        OutputStream fileOutputStream = null;
        BufferedWriter bufferedWriter = null;
        try {
            File folder = new File(htmlPath + "/custom/page-custom/js/");
            folder.mkdirs();
            folder = new File(htmlPath + "/custom/page-custom/image/");
            folder.mkdirs();
            file = new File(htmlPath + "/custom/page-custom/js/custom-function.js");
            //如果文件不存在，则创建文件，如果已存在，则覆盖
            if (!file.exists()) {
                file.createNewFile();
                fileOutputStream = new FileOutputStream(file);
                bufferedWriter = new BufferedWriter(new OutputStreamWriter(fileOutputStream, "utf-8"));
                bufferedWriter.write(
                        "//------------------need custom modify function---------------\n" +
                                "\n" +
                                "var checkError = function (res) {\n" +
                                "    if (res.status == 666005 || res.status == 666002 || res.status == 666003) {\n" +
                                "        showAlertFrame(res.message);\n" +
                                "        logoutOnly();\n" +
                                "        gotoAuthUrl();\n" +
                                "    } else {\n" +
                                "        if (res.status == 0) {\n" +
                                "            return;\n" +
                                "        }\n" +
                                "        showAlertFrame(res.message);\n" +
                                "    }\n" +
                                "}\n" +
                                "\n" +
                                "var gotoAuthUrl = function () {\n" +
                                "    if ( location.href.indexOf(\"/index.html\") > 0 ) {\n" +
                                "    } else if (location.href.indexOf(\".html\") < 0) {\n" +
                                "    } else {\n" +
                                "        location.href = \"../../../authorize/login/page.html?redirectUrl=\" + location.href;\n" +
                                "    }\n" +
                                "}\n" +
                                "\n" +
                                "var gotoUrl = function (url) {\n" +
                                "    location.href = url;\n" +
                                "}\n" +
                                "\n" +
                                "var gotoUrlInThisPage = function (url) {\n" +
                                "    location.href = url;\n" +
                                "}\n" +
                                "\n" +
                                "var getLocalStorageUrlKey = function (url) {\n" +
                                "    return getSellerId() + \"_\" + url;\n" +
                                "}\n" +
                                "\n" +
                                "var getSellerId = function () {\n" +
                                "    if (getLocalStorageItem(\"seller\") == undefined) {\n" +
                                "        return undefined;\n" +
                                "    }\n" +
                                "    var seller = JSON.parse(getLocalStorageItem(\"seller\"));\n" +
                                "    if(seller==null){\n" +
                                "        return undefined;\n" +
                                "    }\n" +
                                "    return seller.id;\n" +
                                "}\n" +
                                "\n" +
                                "\n");
                System.out.println("write to file success : " + file.getPath());
            } else {
                System.out.println("write to file jump success : " + file.getPath());
            }
        } catch (IOException e) {
            e.printStackTrace();
        } finally {
            MybatisUtilCommon.closeBufferWriterAndFileOutputStream(fileOutputStream, bufferedWriter);
        }
    }

    public static void writeCustomPageCustomJsCustomValueJs(String htmlPath, String serverUrl) {
        File file = null;
        OutputStream fileOutputStream = null;
        BufferedWriter bufferedWriter = null;
        try {
            File folder = new File(htmlPath + "/custom/page-custom/js/");
            folder.mkdirs();
            file = new File(htmlPath + "/custom/page-custom/js/custom-value.js");
            //如果文件不存在，则创建文件，如果已存在，则覆盖
            if (!file.exists()) {
                file.createNewFile();
                fileOutputStream = new FileOutputStream(file);
                bufferedWriter = new BufferedWriter(new OutputStreamWriter(fileOutputStream, "utf-8"));
                bufferedWriter.write(
                        "//var SERVER-URL_CURRENT = \"http://localhost:10666\";\n" +
                                "var SERVER_URL_CURRENT = \"" + serverUrl + "\";\n" +
                                "// var SERVER_URL_CURRENT = \"https://www.fooolie.com/process\";\n" +
                                "var UPLOAD_VIDEO_SIZE_LIMIT=5000000;\n" +
                                "var UPLOAD_IMAGE_SIZE_LIMIT=500000;\n" +
                                "var UPLOAD_FILE_SIZE_LIMIT=1000000;");
                System.out.println("write to file success : " + file.getPath());
            } else {
                System.out.println("write to file jump success : " + file.getPath());
            }
        } catch (IOException e) {
            e.printStackTrace();
        } finally {
            MybatisUtilCommon.closeBufferWriterAndFileOutputStream(fileOutputStream, bufferedWriter);
        }
    }

    public static void writeCustomPageCustomCssCustomCss(String htmlPath, String serverUrl, String type) {
        File file = null;
        OutputStream fileOutputStream = null;
        BufferedWriter bufferedWriter = null;
        try {
            File folder = new File(htmlPath + "/custom/page-custom/css/");
            folder.mkdirs();
            file = new File(htmlPath + "/custom/page-custom/css/custom" + type + ".css");
            //如果文件不存在，则创建文件，如果已存在，则覆盖
            if (!file.exists()) {
                file.createNewFile();
                fileOutputStream = new FileOutputStream(file);
                bufferedWriter = new BufferedWriter(new OutputStreamWriter(fileOutputStream, "utf-8"));
                bufferedWriter.write(
                        "");
                System.out.println("write to file success : " + file.getPath());
            } else {
                System.out.println("write to file jump success : " + file.getPath());
            }
        } catch (IOException e) {
            e.printStackTrace();
        } finally {
            MybatisUtilCommon.closeBufferWriterAndFileOutputStream(fileOutputStream, bufferedWriter);
        }
    }

    public static void writeTablePage(IntrospectedTable introspectedTable, String htmlPath, String modelUrl, String fileUploadServer, String serverUrl, String basePackage, String aspectPackage, String type, String typeDescription) {
        String tableName = MybatisUtilCommon.getTableName(introspectedTable, modelUrl);
        String tableOriginalName = introspectedTable.getFullyQualifiedTable().getIntrospectedTableName();
        String[] tableNames = tableOriginalName.split("_");
        if (tableNames.length < 2) {
            tableNames = (tableOriginalName + "_page").split("_");
        }
        String tableOriginalNameReplaceWithBar = tableOriginalName.replaceAll("_", "-");
        File file = null;
        OutputStream outputStream = null;
        BufferedWriter bufferedWriter = null;
        try {
            File folder = new File(htmlPath + "/" + tableNames[0] + "/" + tableNames[1] + "/" + tableOriginalNameReplaceWithBar + "-" + type + "/");
            folder.mkdirs();
            String fileString = htmlPath + "/" + tableNames[0] + "/" + tableNames[1] + "/" + tableOriginalNameReplaceWithBar + "-" + type + "/page.html";
            /** 创建文件，有则直接覆盖掉 */
            file = new File(fileString);
            file.createNewFile();
            outputStream = new FileOutputStream(file);
            bufferedWriter = new BufferedWriter(new OutputStreamWriter(outputStream, "utf-8"));
            bufferedWriter.write("<!DOCTYPE html>\n");
            bufferedWriter.write("<html lang=\"zh-CN\">\n");
            writeHead(introspectedTable, tableName, bufferedWriter, "../../.." + "/custom/" + tableNames[0] + "/" + tableNames[1] + "/" + tableOriginalNameReplaceWithBar + "-" + type + "", typeDescription, type);
            writeBody(introspectedTable, tableName, bufferedWriter);
            bufferedWriter.write("</html>\n");
            System.out.println("write to file success : " + file.getPath());
        } catch (IOException e) {
            e.printStackTrace();
        } finally {
            MybatisUtilCommon.closeBufferWriterAndFileOutputStream(outputStream, bufferedWriter);
        }
    }

    public static void writeCustomTableJsPage(IntrospectedTable introspectedTable, String htmlPath, String modelUrl, String fileUploadServer, String serverUrl, String basePackage, String aspectPackage, String type) {
        String tableName = MybatisUtilCommon.getTableName(introspectedTable, modelUrl);
        String tableOriginalName = introspectedTable.getFullyQualifiedTable().getIntrospectedTableName();
        String[] tableNames = tableOriginalName.split("_");
        if (tableNames.length < 2) {
            tableNames = (tableOriginalName + "_page").split("_");
        }
        String tableOriginalNameReplaceWithBar = tableOriginalName.replaceAll("_", "-");
        String tableOriginalNameReplaceWithSlash = tableOriginalName.replaceAll("_", "/");
        File file = null;
        OutputStream outputStream = null;
        BufferedWriter bufferedWriter = null;
        try {
            File folder = new File(htmlPath + "/custom/" + tableNames[0] + "/" + tableNames[1] + "/" + tableOriginalNameReplaceWithBar + "-" + type + "/js/");
            folder.mkdirs();
            String fileString = htmlPath + "/custom/" + tableNames[0] + "/" + tableNames[1] + "/" + tableOriginalNameReplaceWithBar + "-" + type + "/js/custom-page.js";
            file = new File(fileString);
            if (file.exists()) {
                return;
            }
            file.createNewFile();
            outputStream = new FileOutputStream(file);
            bufferedWriter = new BufferedWriter(new OutputStreamWriter(outputStream, "utf-8"));
            bufferedWriter.write("");
            //如果type包含preview则会存入自定义是否下载字段
            if (type.contains("preview")) {
                List<Map> fileList = MybatisUtilCommon.getFileListFromConfigFile();
                for (int i = 0; i < fileList.size(); i++) {
                    Map fileMap = fileList.get(i);
                    String tableIntrospectedTableName = (String) fileMap.get("tableIntrospectedTableName");
                    String tableDomainObjectName = (String) fileMap.get("tableDomainObjectName");
                    List<Object> fieldOriginalNames = (List) fileMap.get("fieldOriginalNames");
                    for (int j = 0; j < fieldOriginalNames.size(); j++) {
                        String originalName = (String) fieldOriginalNames.get(j);
                        if (originalName.equals(tableOriginalName + "_id")) {
                            bufferedWriter.write("var getInformationOf" + tableDomainObjectName + "=1;\n");
                        }
                    }
                }
                bufferedWriter.write("var getMainProcessWithClassNameAndListLimit" + MybatisUtilCommon.toTransferTableNameToObjectName(type.replace("-", "_")) + "=36;\n");
                bufferedWriter.write("var getInformationOf" + introspectedTable.getFullyQualifiedTable().getDomainObjectName() + "=1;\n");
            }
            System.out.println("write to file success : " + file.getPath());
        } catch (IOException e) {
            e.printStackTrace();
        } finally {
            MybatisUtilCommon.closeBufferWriterAndFileOutputStream(outputStream, bufferedWriter);
        }
    }

    public static void writeCustomTableCssPage(IntrospectedTable introspectedTable, String htmlPath, String modelUrl, String fileUploadServer, String serverUrl, String basePackage, String aspectPackage, String type) {
        String tableName = MybatisUtilCommon.getTableName(introspectedTable, modelUrl);
        String tableOriginalName = introspectedTable.getFullyQualifiedTable().getIntrospectedTableName();
        String[] tableNames = tableOriginalName.split("_");
        if (tableNames.length < 2) {
            tableNames = (tableOriginalName + "_page").split("_");
        }
        String tableOriginalNameReplaceWithBar = tableOriginalName.replaceAll("_", "-");
        File file = null;
        OutputStream outputStream = null;
        BufferedWriter bufferedWriter = null;
        try {
            File folder = new File(htmlPath + "/custom/" + tableNames[0] + "/" + tableNames[1] + "/" + tableOriginalNameReplaceWithBar + "-" + type + "/css/");
            folder.mkdirs();
            String fileString = htmlPath + "/custom/" + tableNames[0] + "/" + tableNames[1] + "/" + tableOriginalNameReplaceWithBar + "-" + type + "/css/custom-page.css";
            file = new File(fileString);
            file.createNewFile();
            if (file.exists()) {
                return;
            }
            outputStream = new FileOutputStream(file);
            bufferedWriter = new BufferedWriter(new OutputStreamWriter(outputStream, "utf-8"));
            bufferedWriter.write("\n");
            System.out.println("write to file success : " + file.getPath());
        } catch (IOException e) {
            e.printStackTrace();
        } finally {
            MybatisUtilCommon.closeBufferWriterAndFileOutputStream(outputStream, bufferedWriter);
        }
    }

    private static void writeHead(IntrospectedTable introspectedTable, String tableName, BufferedWriter bufferedWriter, String customPath, String typeDescription, String type) throws IOException {
        bufferedWriter.write("<head>\n" +
                "    <meta charset=\"UTF-8\">\n" +
                "    <meta http-equiv=\"content-type\" content=\"text/html; charset=utf-8\">\n" +
                "    <meta http-equiv=\"X-UA-Compatible\" content=\"IE=Edge\">\n" +
                "    <meta name=\"viewport\"\n" +
                "          content=\"width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no\">\n" +
                "    <meta name=\"apple-mobile-web-app-status-bar-style\" content=\"black\">\n" +
                "    <meta name=\"referrer\" content=\"always\">\n" +
                "    <meta http-equiv=\"Cache-Control\" content=\"max-age=31536000\"/>\n" +
                "    <link rel=\"shortcut icon\" href=\"../../../favicon.ico\" type=\"image/x-icon\"/>\n" +
                "\n" +
                "    <title>" + introspectedTable.getRemarks() + "-" + typeDescription + "</title>\n" +
                "\n" +
                "    <script src=\"../../../common/page-common/js/jquery.js\"></script>\n" +
                "    <script src=\"../../../common/page-common/js/jquery-ui.js\"></script>\n" +
                "    <script type=\"text/javascript\" src=\"../../../common/page-common/js/sha256.js\"></script>\n" +
                "    <script type=\"text/javascript\" src=\"../../../common/page-common/js/jcompress.js\"></script>\n" +
                "    <script type=\"text/javascript\" src=\"js/page.js\"></script>\n" +
                "    <link rel=\"stylesheet\" type=\"text/css\" href=\"css/page.css\"/>\n" +
                "    <link rel=\"stylesheet\" type=\"text/css\" href=\"../../../common/page-common/css/jquery-ui.css\"/>\n" +
                "    <link rel=\"stylesheet\" type=\"text/css\" href=\"../../../common/page-share/css/common.css\"/>\n" +
                "    <link rel=\"stylesheet\" type=\"text/css\" href=\"../../../custom/page-custom/css/custom.css\"/>\n" +
                "    <link rel=\"stylesheet\" type=\"text/css\" href=\"../../../custom/page-custom/css/custom-" + type + ".css\"/>\n" +
                "    <script type=\"text/javascript\" src=\"../../../common/page-share/js/common-function.js\"></script>\n" +
                "    <script type=\"text/javascript\" src=\"../../../common/page-share/js/common-value.js\"></script>\n" +
                "    <script type=\"text/javascript\" src=\"../../../common/page-share/js/common-tables-columns.js\"></script>\n" +
                "    <script type=\"text/javascript\" src=\"../../../custom/page-custom/js/custom-function.js\"></script>\n" +
                "    <script type=\"text/javascript\" src=\"../../../custom/page-custom/js/custom-value.js\"></script>\n" +
                "    <script type=\"text/javascript\" src=\"" + customPath + "/js/custom-page.js\"></script>\n" +
                "    <link rel=\"stylesheet\" type=\"text/css\" href=\"" + customPath + "/css/custom-page.css\" />\n" +
                "\n" +
                "</head>");
    }

    private static void writeBody(IntrospectedTable introspectedTable, String tableName, BufferedWriter bufferedWriter) throws IOException {
        bufferedWriter.write("\n" +
                "<body>\n" +
                "<div class='class-div-top'></div>\n" +
                "<div class=\"class-div-article\" >\n" +
                "    <div class=\"class-div-main-outer\" style=\"\">\n" +
                "        <div class=\"class-div-main\"></div>\n" +
                "    </div>\n" +
                "</div>\n" +
                "<div class=\"class-div-footer\">\n" +
                "</div>\n" +
                "</body>");
    }

    public static void writeCssPage(IntrospectedTable introspectedTable, String htmlPath, String modelUrl, String fileUploadServer, String serverUrl, String basePackage, String aspectPackage, String type) {
        String tableName = MybatisUtilCommon.getTableName(introspectedTable, modelUrl);
        String tableOriginalName = introspectedTable.getFullyQualifiedTable().getIntrospectedTableName();
        String[] tableNames = tableOriginalName.split("_");
        if (tableNames.length < 2) {
            tableNames = (tableOriginalName + "_page").split("_");
        }
        String tableOriginalNameReplaceWithBar = tableOriginalName.replaceAll("_", "-");
        File file = null;
        OutputStream outputStream = null;
        BufferedWriter bufferedWriter = null;
        try {
            File folder = new File(htmlPath + "/" + tableNames[0] + "/" + tableNames[1] + "/" + tableOriginalNameReplaceWithBar + "-" + type + "/css/");
            folder.mkdirs();
            String fileString = htmlPath + "/" + tableNames[0] + "/" + tableNames[1] + "/" + tableOriginalNameReplaceWithBar + "-" + type + "/css/page.css";
            file = new File(fileString);
            file.createNewFile();
            outputStream = new FileOutputStream(file);
            bufferedWriter = new BufferedWriter(new OutputStreamWriter(outputStream, "utf-8"));
            bufferedWriter.write("\n");
            System.out.println("write to file success : " + file.getPath());
        } catch (IOException e) {
            e.printStackTrace();
        } finally {
            MybatisUtilCommon.closeBufferWriterAndFileOutputStream(outputStream, bufferedWriter);
        }
    }

    public static void writeTableJsCreatePage(IntrospectedTable introspectedTable, String htmlPath, String modelUrl, String fileUploadServer, String serverUrl, String basePackage, String aspectPackage) {
        String tableName = MybatisUtilCommon.getTableName(introspectedTable, modelUrl);
        String tableOriginalName = introspectedTable.getFullyQualifiedTable().getIntrospectedTableName();
        String[] tableNames = tableOriginalName.split("_");
        if (tableNames.length < 2) {
            tableNames = (tableOriginalName + "_page").split("_");
        }
        String tableOriginalNameReplaceWithBar = tableOriginalName.replaceAll("_", "-");
        File file = null;
        OutputStream outputStream = null;
        BufferedWriter bufferedWriter = null;
        try {
            File folder = new File(htmlPath + "/" + tableNames[0] + "/" + tableNames[1] + "/" + tableOriginalNameReplaceWithBar + "-create/js/");
            folder.mkdirs();
            String fileString = htmlPath + "/" + tableNames[0] + "/" + tableNames[1] + "/" + tableOriginalNameReplaceWithBar + "-create/js/page.js";
            file = new File(fileString);
            file.createNewFile();
            outputStream = new FileOutputStream(file);
            bufferedWriter = new BufferedWriter(new OutputStreamWriter(outputStream, "utf-8"));

            List<IntrospectedColumn> introspectedColumns = introspectedTable.getAllColumns();
            List<String> ids = new ArrayList<>();
            List<String> javaProperties = new ArrayList<>();
            for (int i = 0; i < introspectedColumns.size(); i++) {
                IntrospectedColumn introspectedColumn = introspectedColumns.get(i);
                if (introspectedColumn.getActualColumnName().endsWith("_id")) {
                    ids.add(introspectedColumn.getActualColumnName());
                    javaProperties.add(MybatisUtilCommon.toLowerCaseAtFirstCharacter(introspectedColumn.getJavaProperty()));
                }
            }
            bufferedWriter.write("$(function () {\n" +
                    "    getMainProcess();\n" +
                    "})\n" +
                    "\n" +
                    "//------common ajax function------\n" +
                    "\n" +
                    "var getMainProcess = function () {\n" +
                    "    $(\".class-div-main\").html(loadingImage);\n" +
                    "    var token = getLocalStorageItem(\"token\");\n" +
                    "    if (token == undefined) {\n" +
                    "        gotoAuthUrl();\n" +
                    "    }\n" +
                    "    showHtml();\n" +
                    "}\n" +
                    "\n" +
                    "//------custom ajax function------\n" +
                    "\n" +
                    "var submitThisItem = function () {\n" +
                    "    var url = SERVER_URL_CURRENT + \"/v1/common/" + MybatisUtilCommon.getTableNameWithSlash(introspectedTable) + "/create\";\n" +
                    "    var token = getLocalStorageItem(\"token\");\n" +
                    "    if (token == undefined) {\n" +
                    "        gotoAuthUrl();\n" +
                    "    }\n" +
                    "    var item = {};\n");
            for (int i = 0; i < introspectedColumns.size(); i++) {
                IntrospectedColumn introspectedColumn = introspectedColumns.get(i);
                if (!introspectedColumn.isAutoIncrement()) {
                    if (introspectedColumn.getActualColumnName().contains("password")) {
                        bufferedWriter.write("    item." + MybatisUtilCommon.toLowerCaseAtFirstCharacter(introspectedColumn.getJavaProperty()) + " = sha256($(\".class-input-" + introspectedTable.getFullyQualifiedTable().getIntrospectedTableName() + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "\").val());\n");
                    } else if (!introspectedColumn.getActualColumnName().equals("create_time") && !introspectedColumn.getActualColumnName().equals("update_time") && !introspectedColumn.getActualColumnName().equals("status")) {
                        bufferedWriter.write("    item." + MybatisUtilCommon.toLowerCaseAtFirstCharacter(introspectedColumn.getJavaProperty()) + " = $(\".class-input-" + introspectedTable.getFullyQualifiedTable().getIntrospectedTableName() + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "\").val();\n");
                    } else if (introspectedColumn.getActualColumnName().equals("status")) {
                        bufferedWriter.write("    item." + MybatisUtilCommon.toLowerCaseAtFirstCharacter(introspectedColumn.getJavaProperty()) + " = 1;\n");
                    }
                }
            }
            bufferedWriter.write("    $.ajax({\n" +
                    "        url: url,\n" +
                    "        type: \"post\",\n" +
                    "        contentType: \"application/json\",\n" +
                    "        accept: \"application/json\",\n" +
                    "        cache: false,\n" +
                    "        async: true,\n" +
                    "        headers: {\"token\": token},\n" +
                    "        data: JSON.stringify(item),\n" +
                    "        success: function (res) {\n" +
                    "            if (res.status == 200) {\n" +
                    "                showAlertFrame(res.message);\n" +
                    (javaProperties.size() == 0 ?
                            "                setTimeout(gotoUrlInThisPage(\"../" + tableOriginalNameReplaceWithBar + "-list/page.html\"), 2666);\n" :
                            "                setTimeout(gotoUrlInThisPage(\"../" + tableOriginalNameReplaceWithBar + "-list/page.html?" + javaProperties.get(0) + "=\"+$(\".class-input-" + introspectedTable.getFullyQualifiedTable().getIntrospectedTableName() + "-item-\" + \"" + ids.get(0) + "\").val()+\"\"), 2666);\n") +
                    "            } else {\n" +
                    "                checkError(res);\n" +
                    "            }\n" +
                    "        },\n" +
                    "        error: function (message) {\n" +
                    "            showAlertFrame(ERROR_MESSAGE_CANNOT_CONNECT_TO_SERVER);\n" +
                    "        }\n" +
                    "    });\n" +
                    "}\n" +
                    "\n" +
                    "//------html function------\n" +
                    "\n" +
                    "var showHtml = function () {\n" +
                    "    var mainHtml = \"\";\n" +
                    "    mainHtml += \"<div class='class-div-" + tableOriginalName + "'>\";\n" +
                    "    mainHtml += \"<div class='class-div-item-head class-div-item-head-" + tableOriginalName + "'><span class='class-span-item-head class-span-item-head-" + tableOriginalName + "'>" + introspectedTable.getRemarks() + "资料</span>\" +\n" +
                    "        \"<button class='class-button class-button-submit class-button-submit-" + tableOriginalName + "'>提交</button>\" +\n" +
                    "        \"</div>\";\n");
            for (int i = 0; i < introspectedColumns.size(); i++) {
                IntrospectedColumn introspectedColumn = introspectedColumns.get(i);
                //当字段不是自增，且字段名不是status，create_time，update_time时才要生成输入框
                if (!introspectedColumn.isAutoIncrement() && !introspectedColumn.getActualColumnName().equals("status")
                        && !introspectedColumn.getActualColumnName().equals("create_time") && !introspectedColumn.getActualColumnName().equals("update_time")
                ) {
                    bufferedWriter.write("    mainHtml += \"<div class='class-div-" + tableOriginalName + "-item class-div-" + tableOriginalName + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "'>\" +\n" +
                            "        \"<span class='class-span-item-label class-span-item-label-" + tableOriginalName + " class-span-item-label class-span-item-label-" + tableOriginalName + "-\" + \"" + introspectedColumn.getActualColumnName() + "\" + \"'>" + introspectedColumn.getRemarks().split(":")[0] + " ：</span>\" +\n" +
                            "        \"<span class='class-span-" + tableOriginalName + "-item class-span-" + tableOriginalName + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "'>\" +\n");
                    //根据字段的名称和remark判断是否要做特殊处理
                    String fieldName = introspectedColumn.getActualColumnName();
                    String remark = introspectedColumn.getRemarks();
                    if (fieldName.endsWith("_date") || fieldName.endsWith("_time")) {
                        bufferedWriter.write("        \"<input type='text' class='class-input class-input-date-only class-input-" + tableOriginalName + "-item class-input-" + tableOriginalName + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "' />\" +\n");
                    } else if (fieldName.endsWith("_video")) {
                        bufferedWriter.write("        \"<input type='text' class='class-input class-input-video class-input-" + tableOriginalName + "-item class-input-" + tableOriginalName + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "' />\" +\n");
                    } else if (fieldName.endsWith("_image")) {
                        bufferedWriter.write("        \"<input type='text' class='class-input class-input-image class-input-" + tableOriginalName + "-item class-input-" + tableOriginalName + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "' />\" +\n");
                    } else if (fieldName.endsWith("_file")) {
                        bufferedWriter.write("        \"<input type='text' class='class-input class-input-file class-input-" + tableOriginalName + "-item class-input-" + tableOriginalName + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "' />\" +\n");
                    } else if (fieldName.contains("password")) {
                        bufferedWriter.write("        \"<input type='password' class='class-input class-input-password class-input-" + tableOriginalName + "-item class-input-" + tableOriginalName + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "' />\" +\n");
                    } else if (remark.contains(":")) {
                        try {
                            String option = "";
                            String[] remarks = remark.split(":");
                            String remarkWithoutFirstBlock = "";
                            for (int j = 1; j < remarks.length; j++) {
                                if (j < remarks.length - 1) {
                                    remarkWithoutFirstBlock += remarks[j] + ":";
                                } else {
                                    remarkWithoutFirstBlock += remarks[j];
                                }
                            }
                            remarks = remarkWithoutFirstBlock.split(",");
                            bufferedWriter.write("        \"<select type='text' class='class-input class-input-select class-input-" + tableOriginalName + "-item class-input-" + tableOriginalName + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "' >\" +\n");
                            for (int j = 0; j < remarks.length; j++) {
                                String[] remarkValues = remarks[j].split(":");
                                bufferedWriter.write("        \"<option value='" + remarkValues[0] + "' >" + remarkValues[1] + "</option>\" +\n");
                            }
                            bufferedWriter.write("\"</select>\"+");
                        } catch (Exception e) {
                            bufferedWriter.write("出现错误，请检查数据库的字段注释是否正确的格式:\"字段说明:1:zzz,2:fff,3:ppp\":table:" + tableOriginalName + ":column:" + introspectedColumn.getActualColumnName() + ":remark:" + remark);
                        }
                    } else if (introspectedColumn.isBLOBColumn() || introspectedColumn.getLength() >= 500) {
                        bufferedWriter.write("        \"<textarea class='class-input class-input-textarea class-input-" + tableOriginalName + "-item class-input-" + tableOriginalName + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "' ></textarea>\" +\n");
                    } else {
                        if (javaProperties.size() > 0 && introspectedColumn.getJavaProperty().equals(javaProperties.get(0))) {
                            bufferedWriter.write("        \"<input readOnly type='text' class='class-input class-input-" + tableOriginalName + "-item class-input-" + tableOriginalName + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "' value=\\\"\"+getUrlSplit('" + javaProperties.get(0) + "=')+\"\\\" />\" +\n");
                        } else {
                            bufferedWriter.write("        \"<input type='text' class='class-input class-input-" + tableOriginalName + "-item class-input-" + tableOriginalName + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "' />\" +\n");
                        }
                    }
                    bufferedWriter.write("        \"</span>\" +\n" +
                            "        \"</div>\";\n");
                }
            }
            bufferedWriter.write("    mainHtml += \"</div>\";\n" +
                    "    $(\".class-div-main\").html(mainHtml);\n" +
                    "    getClickButtonFunction();\n" +
                    "}\n" +
                    "\n" +
                    "var getClickButtonFunction = function () {\n" +
                    "    $(\".class-button-submit-" + tableOriginalName + "\").click(function () {\n" +
                    "        submitThisItem();\n" +
                    "    });\n" +
                    "    showDatePicker(\".class-input-date-only\");\n" +
                    "    $(\".class-input-video\").click(function () {;\n" +
                    "       showUploadFrame(this,\"video\");\n" +
                    "    });\n" +
                    "    $(\".class-input-image\").click(function () {;\n" +
                    "       showUploadFrame(this,\"image\");\n" +
                    "    });\n" +
                    "    $(\".class-input-file\").click(function () {;\n" +
                    "       showUploadFrame(this,\"file\");\n" +
                    "    });\n" +
                    "}\n");
            System.out.println("write to file success : " + file.getPath());
        } catch (IOException e) {
            e.printStackTrace();
        } finally {
            MybatisUtilCommon.closeBufferWriterAndFileOutputStream(outputStream, bufferedWriter);
        }
    }

    public static void writeTableJsUpdatePage(IntrospectedTable introspectedTable, String htmlPath, String modelUrl, String fileUploadServer, String serverUrl, String basePackage, String aspectPackage) {
        String tableName = MybatisUtilCommon.getTableName(introspectedTable, modelUrl);
        String tableOriginalName = introspectedTable.getFullyQualifiedTable().getIntrospectedTableName();
        String[] tableNames = tableOriginalName.split("_");
        if (tableNames.length < 2) {
            tableNames = (tableOriginalName + "_page").split("_");
        }
        String tableOriginalNameReplaceWithBar = tableOriginalName.replaceAll("_", "-");
        String tableOriginalNameReplaceWithSlash = tableOriginalName.replaceAll("_", "/");
        String className = introspectedTable.getFullyQualifiedTable().getDomainObjectName();
        String objectName = MybatisUtilCommon.toLowerCaseAtFirstCharacter(className);
        File file = null;
        OutputStream outputStream = null;
        BufferedWriter bufferedWriter = null;
        try {
            File folder = new File(htmlPath + "/" + tableNames[0] + "/" + tableNames[1] + "/" + tableOriginalNameReplaceWithBar + "-update/js/");
            folder.mkdirs();
            String fileString = htmlPath + "/" + tableNames[0] + "/" + tableNames[1] + "/" + tableOriginalNameReplaceWithBar + "-update/js/page.js";
            file = new File(fileString);
            file.createNewFile();
            outputStream = new FileOutputStream(file);
            bufferedWriter = new BufferedWriter(new OutputStreamWriter(outputStream, "utf-8"));
            bufferedWriter.write("" +
                    "$(function () {\n" +
                    "    getMainProcess(SERVER_URL_CURRENT + \"/v1/common/" + tableOriginalNameReplaceWithSlash + "/get\" + " + MybatisUtilCommon.getPathParameterForPrimaryKeyColumns(introspectedTable) + ");\n" +
                    "})\n" +
                    "\n" +
                    "//------common ajax function start------\n" +
                    "\n" +
                    "var getMainProcess = function (url) {\n" +
                    "    if($(\".class-div-main\").html()==\"\"){\n" +
                    "        $(\".class-div-main\").html(loadingImage);\n" +
                    "    }\n" +
                    "    var token = getLocalStorageItem(\"token\");\n" +
                    "    if (token == undefined) {\n" +
                    "        gotoAuthUrl();\n" +
                    "    }\n" +
                    "    var resPast = getLocalStorageItem(getLocalStorageUrlKey(url));\n" +
                    "    if (resPast != undefined) {\n" +
                    "        try {\n" +
                    "            showHtml(JSON.parse(resPast), url);\n" +
                    "        } catch (e) {\n" +
                    "            removeLocalStorageItem(getLocalStorageUrlKey(url));\n" +
                    "        }\n" +
                    "    }\n" +
                    "    $.ajax({\n" +
                    "        url: url,\n" +
                    "        type: \"get\",\n" +
                    "        cache: false,\n" +
                    "        async: true,\n" +
                    "        headers: {\"token\": token},\n" +
                    "        success: function (res) {\n" +
                    "            if (res.status == 200) {\n" +
                    "                setLocalStorageItem(getLocalStorageUrlKey(url), JSON.stringify(res));\n" +
                    "                showHtml(res, url);\n" +
                    "            } else {\n" +
                    "                checkError(res);\n" +
                    "            }\n" +
                    "        },\n" +
                    "        error: function (message) {\n" +
                    "            showAlertFrame(ERROR_MESSAGE_CANNOT_CONNECT_TO_SERVER);\n" +
                    "        }\n" +
                    "    });\n" +
                    "}\n" +
                    "\n" +
                    "//------custom ajax function start------\n" +
                    "var updateThisItem = function () {\n" +
                    "    var url = SERVER_URL_CURRENT + \"/v1/common/" + tableOriginalNameReplaceWithSlash + "/update\";\n" +
                    "    var token = getLocalStorageItem(\"token\");\n" +
                    "    if (token == undefined) {\n" +
                    "        gotoAuthUrl();\n" +
                    "    }\n" +
                    "    var item = {};\n");

            List<IntrospectedColumn> introspectedColumns = introspectedTable.getAllColumns();
            for (int i = 0; i < introspectedColumns.size(); i++) {
                IntrospectedColumn introspectedColumn = introspectedColumns.get(i);
                if (!introspectedColumn.getActualColumnName().equals("update_time") && !introspectedColumn.getActualColumnName().equals("status")) {
                    bufferedWriter.write("    item." + MybatisUtilCommon.toLowerCaseAtFirstCharacter(introspectedColumn.getJavaProperty()) + " = $(\".class-input-" + introspectedTable.getFullyQualifiedTable().getIntrospectedTableName() + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "\").val();\n");
                } else if (introspectedColumn.getActualColumnName().equals("status")) {
                    bufferedWriter.write("    item." + MybatisUtilCommon.toLowerCaseAtFirstCharacter(introspectedColumn.getJavaProperty()) + " = 1;\n");
                }
            }
            List<String> ids = new ArrayList<>();
            List<String> javaProperties = new ArrayList<>();
            for (int i = 0; i < introspectedColumns.size(); i++) {
                IntrospectedColumn introspectedColumn = introspectedColumns.get(i);
                if (introspectedColumn.getActualColumnName().endsWith("_id")) {
                    ids.add(introspectedColumn.getActualColumnName());
                    javaProperties.add(MybatisUtilCommon.toLowerCaseAtFirstCharacter(introspectedColumn.getJavaProperty()));
                }
            }
            bufferedWriter.write("    $.ajax({\n" +
                    "        url: url,\n" +
                    "        type: \"post\",\n" +
                    "        contentType: \"application/json\",\n" +
                    "        accept: \"application/json\",\n" +
                    "        cache: false,\n" +
                    "        async: true,\n" +
                    "        headers: {\"token\": token},\n" +
                    "        data: JSON.stringify(item),\n" +
                    "        success: function (res) {\n" +
                    "            if (res.status == 200) {\n" +
                    "                showAlertFrame(res.message);\n" +
                    (javaProperties.size() == 0 ?
                            "                setTimeout(gotoUrlInThisPage(\"../" + tableOriginalNameReplaceWithBar + "-list/page.html\"), 2666);\n" :
                            "                setTimeout(gotoUrlInThisPage(\"../" + tableOriginalNameReplaceWithBar + "-list/page.html?" + javaProperties.get(0) + "=\"+$(\".class-input-" + introspectedTable.getFullyQualifiedTable().getIntrospectedTableName() + "-item-\" + \"" + ids.get(0) + "\").val()+\"\"), 2666);\n") +
                    "            } else {\n" +
                    "                checkError(res);\n" +
                    "            }\n" +
                    "        },\n" +
                    "        error: function (message) {\n" +
                    "            showAlertFrame(ERROR_MESSAGE_CANNOT_CONNECT_TO_SERVER);\n" +
                    "        }\n" +
                    "    });\n" +
                    "}\n" +
                    "\n" +
                    "var deleteThisItem = function (id) {\n");
            if (MybatisUtilCommon.getTableHasStatus(introspectedTable)) {
                bufferedWriter.write("    var url = SERVER_URL_CURRENT + \"/v1/common/" + tableOriginalNameReplaceWithSlash + "/delete/set/status\"+ " + MybatisUtilCommon.getPathParameterForPrimaryKeyColumns(introspectedTable) + ";\n");
            } else {
                bufferedWriter.write("    var url = SERVER_URL_CURRENT + \"/v1/common/" + tableOriginalNameReplaceWithSlash + "/delete\"+ " + MybatisUtilCommon.getPathParameterForPrimaryKeyColumns(introspectedTable) + ";\n");
            }
            bufferedWriter.write("    var token = getLocalStorageItem(\"token\");\n" +
                    "    if (token == undefined) {\n" +
                    "        gotoAuthUrl();\n" +
                    "    }\n" +
                    "    $.ajax({\n" +
                    "        url: url,\n" +
                    "        type: \"get\",\n" +
                    "        contentType: \"application/json\",\n" +
                    "        accept: \"application/json\",\n" +
                    "        cache: false,\n" +
                    "        async: true,\n" +
                    "        headers: {\"token\": token},\n" +
                    "        success: function (res) {\n" +
                    "            if (res.status == 200) {\n" +
                    "                showAlertFrame(res.message);\n" +
                    (javaProperties.size() == 0 ?
                            "                setTimeout(gotoUrlInThisPage(\"../" + tableOriginalNameReplaceWithBar + "-list/page.html\"), 2666);\n" :
                            "                setTimeout(gotoUrlInThisPage(\"../" + tableOriginalNameReplaceWithBar + "-list/page.html?" + javaProperties.get(0) + "=\"+$(\".class-input-" + introspectedTable.getFullyQualifiedTable().getIntrospectedTableName() + "-item-\" + \"" + ids.get(0) + "\").val()+\"\"), 2666);\n") +
                    "            } else {\n" +
                    "                checkError(res);\n" +
                    "            }\n" +
                    "        },\n" +
                    "        error: function (message) {\n" +
                    "            showAlertFrame(ERROR_MESSAGE_CANNOT_CONNECT_TO_SERVER);\n" +
                    "        }\n" +
                    "    });\n" +
                    "}\n" +
                    "/*------custom ajax function end------*/\n" +
                    "\n" +
                    "var showHtml = function (res, url) {\n" +
                    "    var mainHtml = \"\";\n" +
                    "    var item = res.data;\n" +
                    "    mainHtml += \"<div class='class-div-" + tableOriginalName + "'>\";\n" +
                    "    mainHtml += \"<div class='class-div-item-head class-div-item-head-" + tableOriginalName + "'>\" +\n" +
                    "        \"<span class='class-span-item-head class-span-item-head-" + tableOriginalName + "'>" + introspectedTable.getRemarks() + "</span>\" +\n" +
                    "        \"<button class='class-button class-button-update class-button-update-" + tableOriginalName + "'>更改</button>\" +\n" +
                    "        \"<button class='class-button class-button-delete class-button-delete-" + tableOriginalName + "'>删除</button>\" +\n" +
                    "        \"</div>\";\n" +
                    "    if (item != undefined) {\n");

            for (int i = 0; i < introspectedColumns.size(); i++) {
                IntrospectedColumn introspectedColumn = introspectedColumns.get(i);
                //当字段不是自增，且字段名不是status，create_time，update_time时才要生成输入框
                if (!introspectedColumn.getActualColumnName().equals("status")
                        && !introspectedColumn.getActualColumnName().equals("create_time") && !introspectedColumn.getActualColumnName().equals("update_time")
                ) {
                    bufferedWriter.write("    mainHtml += \"<div class='class-div-" + tableOriginalName + "-item class-div-" + tableOriginalName + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "'>\" +\n" +
                            "        \"<span class='class-span-item-label class-span-item-label-" + tableOriginalName + " class-span-item-label class-span-item-label-" + tableOriginalName + "-\" + \"" + introspectedColumn.getActualColumnName() + "\" + \"'>" + introspectedColumn.getRemarks().split(":")[0] + " ：</span>\" +\n" +
                            "        \"<span class='class-span-" + tableOriginalName + "-item class-span-" + tableOriginalName + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "'>\" +\n");

                    //根据字段的名称和remark判断是否要做特殊处理
                    String fieldName = introspectedColumn.getActualColumnName();
                    String remark = introspectedColumn.getRemarks();
                    if (fieldName.endsWith("_date") || fieldName.endsWith("_time")) {
                        bufferedWriter.write("        \"<input type='text' class='class-input class-input-date-only class-input-" + tableOriginalName + "-item class-input-" + tableOriginalName + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "' value='\"+item." + introspectedColumn.getJavaProperty() + "+\"' />\" +\n");
                    } else if (fieldName.endsWith("_video")) {
                        bufferedWriter.write("        \"<input type='text' class='class-input class-input-video class-input-" + tableOriginalName + "-item class-input-" + tableOriginalName + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "' value='\"+item." + introspectedColumn.getJavaProperty() + "+\"' />\" +\n");
                    } else if (fieldName.endsWith("_image")) {
                        bufferedWriter.write("        \"<input type='text' class='class-input class-input-image class-input-" + tableOriginalName + "-item class-input-" + tableOriginalName + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "' value='\"+item." + introspectedColumn.getJavaProperty() + "+\"' />\" +\n");
                    } else if (fieldName.endsWith("_file")) {
                        bufferedWriter.write("        \"<input type='text' class='class-input class-input-file class-input-" + tableOriginalName + "-item class-input-" + tableOriginalName + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "' value='\"+item." + introspectedColumn.getJavaProperty() + "+\"' />\" +\n");
                    } else if (remark.contains(":")) {
                        try {
                            String option = "";
                            String[] remarks = remark.split(":");
                            String remarkWithoutFirstBlock = "";
                            for (int j = 1; j < remarks.length; j++) {
                                if (j < remarks.length - 1) {
                                    remarkWithoutFirstBlock += remarks[j] + ":";
                                } else {
                                    remarkWithoutFirstBlock += remarks[j];
                                }
                            }
                            remarks = remarkWithoutFirstBlock.split(",");
                            bufferedWriter.write("        \"<select type='text' class='class-input class-input-select class-input-" + tableOriginalName + "-item class-input-" + tableOriginalName + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "' >\" +\n");
                            for (int j = 0; j < remarks.length; j++) {
                                String[] remarkValues = remarks[j].split(":");
                                bufferedWriter.write("        \"<option value='" + remarkValues[0] + "' \"+( item." + introspectedColumn.getJavaProperty() + "=='" + remarkValues[0] + "'?\"selected\":\"\")+\" >" + remarkValues[1] + "</option>\" +\n");
                            }
                            bufferedWriter.write("\"        </select>\"+\n");
                        } catch (Exception e) {
                            bufferedWriter.write("出现错误，请检查数据库的字段注释是否正确的格式:\"字段说明:1:zzz,2:fff,3:ppp\":table:" + tableOriginalName + ":column:" + introspectedColumn.getActualColumnName() + ":remark:" + remark);
                        }
                    } else if (introspectedColumn.isBLOBColumn() || introspectedColumn.getLength() >= 500) {
                        bufferedWriter.write("        \"<textarea class='class-input class-input-textarea class-input-" + tableOriginalName + "-item class-input-" + tableOriginalName + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "' >\"+item." + introspectedColumn.getJavaProperty() + "+\"</textarea>\" +\n");
                    } else if (introspectedColumn.getActualColumnName().contains("password")) {
                        bufferedWriter.write("        \"<input readonly type='password' class='class-input class-input-password class-input-" + tableOriginalName + "-item class-input-" + tableOriginalName + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "' value='\"+item." + introspectedColumn.getJavaProperty() + "+\"' />\" +\n");
                    } else {
                        bufferedWriter.write("        \"<input type='text' class='class-input class-input-" + tableOriginalName + "-item class-input-" + tableOriginalName + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "' value='\"+item." + introspectedColumn.getJavaProperty() + "+\"' />\" +\n");
                    }
                    bufferedWriter.write("        \"</span>\" +\n" +
                            "        \"</div>\";\n");
                } else if (introspectedColumn.getActualColumnName().equals("create_time")) {
                    bufferedWriter.write("    mainHtml += \"<div class='class-div-" + tableOriginalName + "-item class-div-" + tableOriginalName + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "'>\" +\n" +
                            "        \"<span class='class-span-item-label class-span-item-label-" + tableOriginalName + " class-span-item-label class-span-item-label-" + tableOriginalName + "-\" + \"" + introspectedColumn.getActualColumnName() + "\" + \"'>" + introspectedColumn.getRemarks().split(":")[0] + " ：</span>\" +\n" +
                            "        \"<span class='class-span-" + tableOriginalName + "-item class-span-" + tableOriginalName + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "'>\" +\n");

                    bufferedWriter.write("        \"<input readonly type='text' class='class-input class-input-" + tableOriginalName + "-item class-input-" + tableOriginalName + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "' value='\"+timestampToTimeWithT(item." + introspectedColumn.getJavaProperty() + ")+\"' />\" +\n");

                    bufferedWriter.write("        \"</span>\" +\n" +
                            "        \"</div>\";\n");
                } else if (introspectedColumn.getActualColumnName().equals("status")) {
                    bufferedWriter.write("    mainHtml += \"<div class='class-div-" + tableOriginalName + "-item class-div-" + tableOriginalName + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "'>\" +\n" +
                            "        \"<span class='class-span-item-label class-span-item-label-" + tableOriginalName + " class-span-item-label class-span-item-label-" + tableOriginalName + "-\" + \"" + introspectedColumn.getActualColumnName() + "\" + \"'>" + introspectedColumn.getRemarks().split(":")[0] + " ：</span>\" +\n" +
                            "        \"<span class='class-span-" + tableOriginalName + "-item class-span-" + tableOriginalName + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "'>\" +\n");

                    String remark = introspectedColumn.getRemarks();

                    writeValueWithSpan(tableOriginalName, bufferedWriter, introspectedColumn);

                    bufferedWriter.write("        \"</span>\" +\n" +
                            "        \"</div>\";\n");
                }
            }
            bufferedWriter.write("    }\n" +
                    "    mainHtml += \"</div>\";\n" +
                    "    $(\".class-div-main\").html(mainHtml);\n" +
                    "    getClickButtonFunction();\n" +
                    "}\n" +
                    "\n" +
                    "var getClickButtonFunction = function () {\n" +
                    "    $(\".class-button-update-" + tableOriginalName + "\").click(function () {\n" +
                    "        updateThisItem();\n" +
                    "    });\n" +
                    "    $(\".class-button-delete-" + tableOriginalName + "\").click(function () {\n" +
                    "        deleteThisItem(getUrlSplit(\"sellerInformationPayAccountId=\"));\n" +
                    "    });\n" +
                    "    showDatePicker(\".class-input-date-only\");\n" +
                    "    $(\".class-input-video\").click(function () {;\n" +
                    "       showUploadFrame(this,\"video\");\n" +
                    "    });\n" +
                    "    $(\".class-input-image\").click(function () {;\n" +
                    "       showUploadFrame(this,\"image\");\n" +
                    "    });\n" +
                    "    $(\".class-input-file\").click(function () {;\n" +
                    "       showUploadFrame(this,\"file\");\n" +
                    "    });\n" +
                    "    $(\".class-input-password\").click(function () {;\n" +
                    "       showPasswordFrame(this);\n" +
                    "    });\n" +
                    "}\n");
            System.out.println("write to file success : " + file.getPath());
        } catch (IOException e) {
            e.printStackTrace();
        } finally {
            MybatisUtilCommon.closeBufferWriterAndFileOutputStream(outputStream, bufferedWriter);
        }
    }

    public static void writeTableJsListPreviewPage(IntrospectedTable introspectedTable, String htmlPath, String modelUrl, String fileUploadServer, String serverUrl, String basePackage, String aspectPackage) {
        String tableName = MybatisUtilCommon.getTableName(introspectedTable, modelUrl);
        String tableOriginalName = introspectedTable.getFullyQualifiedTable().getIntrospectedTableName();
        String[] tableNames = tableOriginalName.split("_");
        if (tableNames.length < 2) {
            tableNames = (tableOriginalName + "_page").split("_");
        }
        String tableOriginalNameReplaceWithBar = tableOriginalName.replaceAll("_", "-");
        String tableOriginalNameReplaceWithSlash = tableOriginalName.replaceAll("_", "/");
        File file = null;
        OutputStream outputStream = null;
        BufferedWriter bufferedWriter = null;
        try {
            File folder = new File(htmlPath + "/" + tableNames[0] + "/" + tableNames[1] + "/" + tableOriginalNameReplaceWithBar + "-list-preview/js/");
            folder.mkdirs();
            String fileString = htmlPath + "/" + tableNames[0] + "/" + tableNames[1] + "/" + tableOriginalNameReplaceWithBar + "-list-preview/js/page.js";
            file = new File(fileString);
            file.createNewFile();
            outputStream = new FileOutputStream(file);
            bufferedWriter = new BufferedWriter(new OutputStreamWriter(outputStream, "utf-8"));
            bufferedWriter.write("$(function () {\n");
            List<IntrospectedColumn> introspectedColumns = introspectedTable.getAllColumns();
            List<String> ids = new ArrayList<>();
            List<String> javaProperties = new ArrayList<>();
            for (int i = 0; i < introspectedColumns.size(); i++) {
                IntrospectedColumn introspectedColumn = introspectedColumns.get(i);
                if (introspectedColumn.getActualColumnName().endsWith("_id")) {
                    ids.add(introspectedColumn.getActualColumnName());
                    javaProperties.add(MybatisUtilCommon.toLowerCaseAtFirstCharacter(introspectedColumn.getJavaProperty()));
                }
            }
            String url = "";
            if (ids.size() == 1) {
                url = "/list/query/" + ids.get(0).replaceAll("_", "/") + "?status=1&" + javaProperties.get(0) + "=\"+getUrlSplit('" + javaProperties.get(0) + "=')+\"";
            } else {
                url = "/list?status=1";
            }
            url += "&orderBy=id desc";
            bufferedWriter.write("    getMainProcess(SERVER_URL_CURRENT + \"/v1/common/" + tableOriginalNameReplaceWithSlash + url + "\");\n" +
                    "})\n" +
                    "\n" +
                    "/*%%%%%%%%%%%%%common ajax function start%%%%%%%%%%%%%*/\n" +
                    "\n" +
                    "var getMainProcess = function (url) {\n" +
                    "    $(\".class-div-main\").html(loadingImage);\n" +
                    "    var token = getLocalStorageItem(\"token\");\n" +
                    "    if (token == undefined) {\n" +
                    "        gotoAuthUrl();\n" +
                    "    }\n" +
                    "    var resPast = getLocalStorageItem(getLocalStorageUrlKey(url));\n" +
                    "    if (resPast != undefined) {\n" +
                    "        try {\n" +
                    "            showHtml(JSON.parse(resPast), url);\n" +
                    "        } catch (e) {\n" +
                    "            removeLocalStorageItem(getLocalStorageUrlKey(url));\n" +
                    "        }\n" +
                    "    }\n" +
                    "    $.ajax({\n" +
                    "        url: url,\n" +
                    "        type: \"get\",\n" +
                    "        cache: false,\n" +
                    "        async: true,\n" +
                    "        headers: {\"token\": token},\n" +
                    "        success: function (res) {\n" +
                    "            if (res.status == 200) {\n" +
                    "                setLocalStorageItem(getLocalStorageUrlKey(url), JSON.stringify(res));\n" +
                    "                showHtml(res, url);\n" +
                    "            } else {\n" +
                    "                checkError(res);\n" +
                    "            }\n" +
                    "        },\n" +
                    "        error: function (message) {\n" +
                    "            showAlertFrame(ERROR_MESSAGE_CANNOT_CONNECT_TO_SERVER);\n" +
                    "        }\n" +
                    "    });\n" +
                    "}\n" +
                    "\n" +
                    "/*%%%%%%%%%%%%%common ajax function end%%%%%%%%%%%%%*/\n" +
                    "\n" +
                    "var showHtml = function (res, url) {\n" +
                    "    var mainHtml = \"\";\n" +
                    "    mainHtml += \"<div class='class-div-" + tableOriginalName + "'>\";\n" +
                    "    mainHtml += \"<div class='class-div-item-head class-div-item-head-" + tableOriginalName + "'><span class='class-span-item-head class-span-item-head-" + tableOriginalName + "'>" + introspectedTable.getRemarks() + "-列表</span>\" +\n" +
                    "        \"</div>\";\n" +
                    "    mainHtml += getPager(res,url);\n" +
                    "    var items = res.data;\n" +
                    "    if (items.length > 0) {\n" +
                    "        mainHtml += \"<table class='class-table class-table-" + tableOriginalName + "'><tr class='class-tr'>\";\n"
            );

            for (int i = 0; i < introspectedColumns.size(); i++) {
                IntrospectedColumn introspectedColumn = introspectedColumns.get(i);
                bufferedWriter.write(
                        "        mainHtml += \"<th class='class-th'>" + introspectedColumn.getRemarks().split(":")[0] + "</th>\";\n"
                );
            }
//            bufferedWriter.write("        mainHtml += \"<th class='class-th'>操作</th>\";\n");
            bufferedWriter.write("        mainHtml += \"</tr>\";\n");
            bufferedWriter.write("        for (var i = 0; i < items.length; i++) {\n" +
                    "            var item = items[i];\n" +
                    "            mainHtml += \"<tr class='class-tr' " +
                    " onclick=\\\"gotoUrl('../" + tableOriginalNameReplaceWithBar + "-preview/page.html?" + MybatisUtilCommon.toLowerCaseAtFirstCharacter(introspectedTable.getFullyQualifiedTable().getDomainObjectName()) + "Id=\" + item.id+\"')\\\" " +
                    ">\" +\n");
            for (int i = 0; i < introspectedColumns.size(); i++) {
                IntrospectedColumn introspectedColumn = introspectedColumns.get(i);
                bufferedWriter.write("                \"<td class='class-td'>\"+");
                //根据字段的名称和remark判断是否要做特殊处理
                String fieldName = introspectedColumn.getActualColumnName();
                String remark = introspectedColumn.getRemarks();
                if (fieldName.endsWith("_date") || fieldName.endsWith("_time")) {
                    bufferedWriter.write("        \"<span type='text' class='class-span class-span-date-only class-span-" + tableOriginalName + "-item class-span-" + tableOriginalName + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "' >\"+timestampToTime(item." + introspectedColumn.getJavaProperty() + ")+\"</span>\" +\n");
                } else if (fieldName.endsWith("_video")) {
                    bufferedWriter.write("        (item." + introspectedColumn.getJavaProperty() + "==\"\"?\"\":\"<video type='text' class='class-span class-span_video class-span-" + tableOriginalName + "-item class-span-" + tableOriginalName + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "' preload=\\\"none\\\" muted=\\\"muted\\\" controls=\\\"controls\\\"  src='\"+item." + introspectedColumn.getJavaProperty() + "+\"' />\") +\n");
                } else if (fieldName.endsWith("_image")) {
                    bufferedWriter.write("        (item." + introspectedColumn.getJavaProperty() + "==\"\"?\"\":\"<image type='text' class='class-span class-span-image class-span-" + tableOriginalName + "-item class-span-" + tableOriginalName + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "' src='\"+item." + introspectedColumn.getJavaProperty() + "+\"' />\") +\n");
                } else if (fieldName.endsWith("_file")) {
                    bufferedWriter.write("        \"<a type='text' class='class-span class-span-file class-span-" + tableOriginalName + "-item class-span-" + tableOriginalName + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "' href='\"+item." + introspectedColumn.getJavaProperty() + "+\"' >文件下载</a>\" +\n");
                } else if (remark.contains(":")) {
                    writeValueWithSpan(tableOriginalName, bufferedWriter, introspectedColumn);
                } else {
                    bufferedWriter.write("        \"<span type='text' class='class-span class-span-" + tableOriginalName + "-item class-span-" + tableOriginalName + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "' >\"+item." + introspectedColumn.getJavaProperty() + "+\"</span>\" +\n");
                }
                bufferedWriter.write("\"</td>\" +\n");
            }
//            bufferedWriter.write(
//                    "                \"<td>\"+\n" +
//                            "                    \"<button class='class-button class-button-update class-button-update-" + tableOriginalName + "' itemId='\" + item.id + \"'>更改</button>\"+\n" +
//                            "                    \"<button class='class-button class-button-preview class-button-preview-" + tableOriginalName + "' itemId='\" + item.id + \"'>查看</button>\"+\n" +
//                            "                \"</td>\" +\n");

            bufferedWriter.write(
                    "                \"</tr>\";\n" +
                            "        }\n" +
                            "        mainHtml += \"</table>\";\n" +
                            "    }\n" +
                            "    mainHtml += \"</div>\";\n" +
                            "    mainHtml += getPager(res,url);\n" +
                            "    $(\".class-div-main\").html(mainHtml);\n" +
                            "    getClickButtonFunction();\n" +
                            "}\n" +
                            "\n" +
                            "var getClickButtonFunction = function () {\n" +
                            "    $(\".class-button-create-" + tableOriginalName + "\").click(function () {\n" +
                            "        gotoUrl(\"../" + tableOriginalNameReplaceWithBar + "-create/page.html" + (javaProperties.size() == 0 ? "" : "?" + javaProperties.get(0) + "=\"+getUrlSplit(\"" + javaProperties.get(0) + "=\")+\"") +
                            "\");\n" +
                            "    });\n" +
                            "    $(\".class-button-update-" + tableOriginalName + "\").click(function () {\n" +
                            "        var itemId = $(this).attr(\"itemId\");\n" +
                            "        gotoUrl(\"../" + tableOriginalNameReplaceWithBar + "-update/page.html?" + MybatisUtilCommon.toLowerCaseAtFirstCharacter(introspectedTable.getFullyQualifiedTable().getDomainObjectName()) + "Id=\" + itemId);\n" +
                            "    });\n" +
                            "    $(\".class-button-preview-" + tableOriginalName + "\").click(function () {\n" +
                            "        var itemId = $(this).attr(\"itemId\");\n" +
                            "        gotoUrl(\"../" + tableOriginalNameReplaceWithBar + "-preview/page.html?" + MybatisUtilCommon.toLowerCaseAtFirstCharacter(introspectedTable.getFullyQualifiedTable().getDomainObjectName()) + "Id=\" + itemId);\n" +
                            "    });\n" +
                            "}\n");
            System.out.println("write to file success : " + file.getPath());
        } catch (IOException e) {
            e.printStackTrace();
        } finally {
            MybatisUtilCommon.closeBufferWriterAndFileOutputStream(outputStream, bufferedWriter);
        }
    }

    public static void writeTableJsListPage(IntrospectedTable introspectedTable, String htmlPath, String modelUrl, String fileUploadServer, String serverUrl, String basePackage, String aspectPackage) {
        String tableName = MybatisUtilCommon.getTableName(introspectedTable, modelUrl);
        String tableOriginalName = introspectedTable.getFullyQualifiedTable().getIntrospectedTableName();
        String[] tableNames = tableOriginalName.split("_");
        if (tableNames.length < 2) {
            tableNames = (tableOriginalName + "_page").split("_");
        }
        String tableOriginalNameReplaceWithBar = tableOriginalName.replaceAll("_", "-");
        String tableOriginalNameReplaceWithSlash = tableOriginalName.replaceAll("_", "/");
        File file = null;
        OutputStream outputStream = null;
        BufferedWriter bufferedWriter = null;
        try {
            File folder = new File(htmlPath + "/" + tableNames[0] + "/" + tableNames[1] + "/" + tableOriginalNameReplaceWithBar + "-list/js/");
            folder.mkdirs();
            String fileString = htmlPath + "/" + tableNames[0] + "/" + tableNames[1] + "/" + tableOriginalNameReplaceWithBar + "-list/js/page.js";
            file = new File(fileString);
            file.createNewFile();
            outputStream = new FileOutputStream(file);
            bufferedWriter = new BufferedWriter(new OutputStreamWriter(outputStream, "utf-8"));
            bufferedWriter.write("$(function () {\n");
            List<IntrospectedColumn> introspectedColumns = introspectedTable.getAllColumns();
            List<String> ids = new ArrayList<>();
            List<String> javaProperties = new ArrayList<>();
            for (int i = 0; i < introspectedColumns.size(); i++) {
                IntrospectedColumn introspectedColumn = introspectedColumns.get(i);
                if (introspectedColumn.getActualColumnName().endsWith("_id")) {
                    ids.add(introspectedColumn.getActualColumnName());
                    javaProperties.add(MybatisUtilCommon.toLowerCaseAtFirstCharacter(introspectedColumn.getJavaProperty()));
                }
            }
            String url = "";
            if (ids.size() == 1) {
                url = "/list/query/" + ids.get(0).replaceAll("_", "/") + "?status=1&" + javaProperties.get(0) + "=\"+getUrlSplit('" + javaProperties.get(0) + "=')+\"";
            } else {
                url = "/list?status=1";
            }
            url += "&orderBy=id desc";
            bufferedWriter.write("    getMainProcess(SERVER_URL_CURRENT + \"/v1/common/" + tableOriginalNameReplaceWithSlash + url + "\");\n" +
                    "})\n" +
                    "\n" +
                    "/*%%%%%%%%%%%%%common ajax function start%%%%%%%%%%%%%*/\n" +
                    "\n" +
                    "var getMainProcess = function (url) {\n" +
                    "    $(\".class-div-main\").html(loadingImage);\n" +
                    "    var token = getLocalStorageItem(\"token\");\n" +
                    "    if (token == undefined) {\n" +
                    "        gotoAuthUrl();\n" +
                    "    }\n" +
                    "    var resPast = getLocalStorageItem(getLocalStorageUrlKey(url));\n" +
                    "    if (resPast != undefined) {\n" +
                    "        try {\n" +
                    "            showHtml(JSON.parse(resPast), url);\n" +
                    "        } catch (e) {\n" +
                    "            removeLocalStorageItem(getLocalStorageUrlKey(url));\n" +
                    "        }\n" +
                    "    }\n" +
                    "    $.ajax({\n" +
                    "        url: url,\n" +
                    "        type: \"get\",\n" +
                    "        cache: false,\n" +
                    "        async: true,\n" +
                    "        headers: {\"token\": token},\n" +
                    "        success: function (res) {\n" +
                    "            if (res.status == 200) {\n" +
                    "                setLocalStorageItem(getLocalStorageUrlKey(url), JSON.stringify(res));\n" +
                    "                showHtml(res, url);\n" +
                    "            } else {\n" +
                    "                checkError(res);\n" +
                    "            }\n" +
                    "        },\n" +
                    "        error: function (message) {\n" +
                    "            showAlertFrame(ERROR_MESSAGE_CANNOT_CONNECT_TO_SERVER);\n" +
                    "        }\n" +
                    "    });\n" +
                    "}\n" +
                    "\n" +
                    "/*%%%%%%%%%%%%%common ajax function end%%%%%%%%%%%%%*/\n" +
                    "\n" +
                    "var showHtml = function (res, url) {\n" +
                    "    var mainHtml = \"\";\n" +
                    "    mainHtml += \"<div class='class-div-" + tableOriginalName + "'>\";\n" +
                    "    mainHtml += \"<div class='class-div-item-head class-div-item-head-" + tableOriginalName + "'><span class='class-span-item-head class-span-item-head-" + tableOriginalName + "'>" + introspectedTable.getRemarks() + "-列表</span>\" +\n" +
                    "        \"<button class='class-button class-button-create class-button-create-" + tableOriginalName + "'>新建-" + introspectedTable.getRemarks() + "</button>\" +\n" +
                    "        \"</div>\";\n" +
                    "    mainHtml += getPager(res,url);\n" +
                    "    var items = res.data;\n" +
                    "    if (items.length > 0) {\n" +
                    "        mainHtml += \"<table class='class-table class-table-" + tableOriginalName + "'><tr class='class-tr'>\";\n"
            );

            for (int i = 0; i < introspectedColumns.size(); i++) {
                IntrospectedColumn introspectedColumn = introspectedColumns.get(i);
                bufferedWriter.write(
                        "        mainHtml += \"<th class='class-th'>" + introspectedColumn.getRemarks().split(":")[0] + "</th>\";\n"
                );
            }
            bufferedWriter.write(
                    "        mainHtml += \"<th class='class-th'>操作</th></tr>\";\n"
            );
            bufferedWriter.write("        for (var i = 0; i < items.length; i++) {\n" +
                    "            var item = items[i];\n" +
                    "            mainHtml += \"<tr class='class-tr'>\" +\n");

            for (int i = 0; i < introspectedColumns.size(); i++) {
                IntrospectedColumn introspectedColumn = introspectedColumns.get(i);
                bufferedWriter.write("                \"<td class='class-td'>\"+");
                //根据字段的名称和remark判断是否要做特殊处理
                String fieldName = introspectedColumn.getActualColumnName();
                String remark = introspectedColumn.getRemarks();
                if (fieldName.endsWith("_date") || fieldName.endsWith("_time")) {
                    bufferedWriter.write("        \"<span type='text' class='class-span class-span-date-only class-span-" + tableOriginalName + "-item class-span-" + tableOriginalName + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "' >\"+timestampToTime(item." + introspectedColumn.getJavaProperty() + ")+\"</span>\" +\n");
                } else if (fieldName.endsWith("_video")) {
                    bufferedWriter.write("        (item." + introspectedColumn.getJavaProperty() + "==\"\"?\"\":\"<video type='text' class='class-span class-span-video class-span-" + tableOriginalName + "-item class-span-" + tableOriginalName + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "' preload=\\\"none\\\" muted=\\\"muted\\\" controls=\\\"controls\\\"  src='\"+item." + introspectedColumn.getJavaProperty() + "+\"' />\") +\n");
                } else if (fieldName.endsWith("_image")) {
                    bufferedWriter.write("        (item." + introspectedColumn.getJavaProperty() + "==\"\"?\"\":\"<image type='text' class='class-span class-span-image class-span-" + tableOriginalName + "-item class-span-" + tableOriginalName + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "' src='\"+item." + introspectedColumn.getJavaProperty() + "+\"' />\") +\n");
                } else if (fieldName.endsWith("_file")) {
                    bufferedWriter.write("        \"<a type='text' class='class-span class-span-file class-span-" + tableOriginalName + "-item class-span-" + tableOriginalName + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "' href='\"+item." + introspectedColumn.getJavaProperty() + "+\"' >文件下载</a>\" +\n");
                } else if (remark.contains(":")) {
                    writeValueWithSpan(tableOriginalName, bufferedWriter, introspectedColumn);
                } else {
                    bufferedWriter.write("        \"<span type='text' class='class-span class-span-" + tableOriginalName + "-item class-span-" + tableOriginalName + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "' >\"+item." + introspectedColumn.getJavaProperty() + "+\"</span>\" +\n");
                }
                bufferedWriter.write("\"</td>\" +\n");
            }
            bufferedWriter.write(
                    "                \"<td>\"+\n" +
                            "                    \"<button class='class-button class-button-update class-button-update-" + tableOriginalName + "' itemId='\" + item.id + \"'>更改</button>\"+\n" +
                            "                    \"<button class='class-button class-button-update-preview class-button-update-preview-" + tableOriginalName + "' itemId='\" + item.id + \"'>查看</button>\"+\n" +
                            "                \"</td>\" +\n");

            bufferedWriter.write(
                    "                \"</tr>\";\n" +
                            "        }\n" +
                            "        mainHtml += \"</table>\";\n" +
                            "    }\n" +
                            "    mainHtml += \"</div>\";\n" +
                            "    mainHtml += getPager(res,url);\n" +
                            "    $(\".class-div-main\").html(mainHtml);\n" +
                            "    getClickButtonFunction();\n" +
                            "}\n" +
                            "\n" +
                            "var getClickButtonFunction = function () {\n" +
                            "    $(\".class-button-create-" + tableOriginalName + "\").click(function () {\n" +
                            "        gotoUrl(\"../" + tableOriginalNameReplaceWithBar + "-create/page.html" + (javaProperties.size() == 0 ? "" : "?" + javaProperties.get(0) + "=\"+getUrlSplit(\"" + javaProperties.get(0) + "=\")+\"") +
                            "\");\n" +
                            "    });\n" +
                            "    $(\".class-button-update-" + tableOriginalName + "\").click(function () {\n" +
                            "        var itemId = $(this).attr(\"itemId\");\n" +
                            "        gotoUrl(\"../" + tableOriginalNameReplaceWithBar + "-update/page.html?" + MybatisUtilCommon.toLowerCaseAtFirstCharacter(introspectedTable.getFullyQualifiedTable().getDomainObjectName()) + "Id=\" + itemId);\n" +
                            "    });\n" +
                            "    $(\".class-button-update-preview-" + tableOriginalName + "\").click(function () {\n" +
                            "        var itemId = $(this).attr(\"itemId\");\n" +
                            "        gotoUrl(\"../" + tableOriginalNameReplaceWithBar + "-update-preview/page.html?" + MybatisUtilCommon.toLowerCaseAtFirstCharacter(introspectedTable.getFullyQualifiedTable().getDomainObjectName()) + "Id=\" + itemId);\n" +
                            "    });\n" +
                            "}\n");
            System.out.println("write to file success : " + file.getPath());
        } catch (IOException e) {
            e.printStackTrace();
        } finally {
            MybatisUtilCommon.closeBufferWriterAndFileOutputStream(outputStream, bufferedWriter);
        }
    }

    private static void writeValueWithSpanWithMainHtml(String tableOriginalName, BufferedWriter bufferedWriter, IntrospectedColumn introspectedColumn) throws IOException {
        try {
            String[] remarks = introspectedColumn.getRemarks().split(":");
            String remarkWithoutFirstBlock = "";
            for (int j = 1; j < remarks.length; j++) {
                if (j < remarks.length - 1) {
                    remarkWithoutFirstBlock += remarks[j] + ":";
                } else {
                    remarkWithoutFirstBlock += remarks[j];
                }
            }
            remarks = remarkWithoutFirstBlock.split(",");
            bufferedWriter.write("            mainHtml += \"<span type='text' class='class-span class-span-show-or-hide class-span-" + tableOriginalName + "-item class-span-" + tableOriginalName + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "' >\" ;\n");
            for (int j = 0; j < remarks.length; j++) {
                String[] remarkValues = remarks[j].split(":");
                bufferedWriter.write("            mainHtml += \"<span class='class-span-show-or-hide-item' style='\"+( item." + introspectedColumn.getJavaProperty() + "=='" + remarkValues[0] + "'?\"\":\"display:none\")+\"' >" + remarkValues[1] + "</span>\";\n");
            }
            bufferedWriter.write("            mainHtml += \"        </span>\";\n");
        } catch (Exception e) {
            bufferedWriter.write("            mainHtml += \"出现错误，请检查数据库的字段注释是否正确的格式:'字段说明:1:zzz,2:fff,3:ppp':table:" + tableOriginalName + ":column:" + introspectedColumn.getActualColumnName() + ":remark:" + introspectedColumn.getRemarks() + "\";");
        }
    }

    private static void writeValueWithSpan(String tableOriginalName, BufferedWriter bufferedWriter, IntrospectedColumn introspectedColumn) throws IOException {
        try {
            String[] remarks = introspectedColumn.getRemarks().split(":");
            String remarkWithoutFirstBlock = "";
            for (int j = 1; j < remarks.length; j++) {
                if (j < remarks.length - 1) {
                    remarkWithoutFirstBlock += remarks[j] + ":";
                } else {
                    remarkWithoutFirstBlock += remarks[j];
                }
            }
            remarks = remarkWithoutFirstBlock.split(",");
            bufferedWriter.write("        \"<span type='text' class='class-span class-span-show-or-hide class-span-" + tableOriginalName + "-item class-span-" + tableOriginalName + "-item-\" + \"" + introspectedColumn.getActualColumnName() + "' >\" +\n");
            for (int j = 0; j < remarks.length; j++) {
                String[] remarkValues = remarks[j].split(":");
                bufferedWriter.write("        \"<span class='class-span-show-or-hide-item' style='\"+( item." + introspectedColumn.getJavaProperty() + "=='" + remarkValues[0] + "'?\"\":\"display:none\")+\"' >" + remarkValues[1] + "</span>\" +\n");
            }
            bufferedWriter.write("\"        </span>\"+\n");
        } catch (Exception e) {
            bufferedWriter.write("出现错误，请检查数据库的字段注释是否正确的格式:\"字段说明:1:zzz,2:fff,3:ppp\":table:" + tableOriginalName + ":column:" + introspectedColumn.getActualColumnName() + ":remark:" + introspectedColumn.getRemarks());
        }
    }

    public static void writeTableJsPreviewPage(IntrospectedTable introspectedTable, String htmlPath, String modelUrl, String fileUploadServer, String serverUrl, String basePackage, String aspectPackage) {
        String tableOriginalName = introspectedTable.getFullyQualifiedTable().getIntrospectedTableName();
        String[] tableNames = tableOriginalName.split("_");
        if (tableNames.length < 2) {
            tableNames = (tableOriginalName + "_page").split("_");
        }
        String tableOriginalNameReplaceWithBar = tableOriginalName.replaceAll("_", "-");
        String tableOriginalNameReplaceWithSlash = tableOriginalName.replaceAll("_", "/");
        File file = null;
        OutputStream outputStream = null;
        BufferedWriter bufferedWriter = null;
        try {
            File folder = new File(htmlPath + "/" + tableNames[0] + "/" + tableNames[1] + "/" + tableOriginalNameReplaceWithBar + "-preview/js/");
            folder.mkdirs();
            String fileString = htmlPath + "/" + tableNames[0] + "/" + tableNames[1] + "/" + tableOriginalNameReplaceWithBar + "-preview/js/page.js";
            file = new File(fileString);
            file.createNewFile();
            outputStream = new FileOutputStream(file);
            bufferedWriter = new BufferedWriter(new OutputStreamWriter(outputStream, "utf-8"));
            bufferedWriter.write("$(function () {\n" +
                    "    writeBodyAndGetMainProcess();\n" +
                    "})\n" +
                    "\n" +
                    "var writeBodyAndGetMainProcess = function () {\n" +
                    "    var mainHtml = \"\";\n");
            bufferedWriter.write("    mainHtml += \"<div class='class-div-container-parent class-div-" + tableOriginalName + "'></div>\";\n");
            List<Map> fileList = MybatisUtilCommon.getFileListFromConfigFile();
            for (int i = 0; i < fileList.size(); i++) {
                Map fileMap = fileList.get(i);
                String tableIntrospectedTableName = (String) fileMap.get("tableIntrospectedTableName");
                String tableDomainObjectName = (String) fileMap.get("tableDomainObjectName");
                List<Object> fieldOriginalNames = (List) fileMap.get("fieldOriginalNames");
                for (int j = 0; j < fieldOriginalNames.size(); j++) {
                    String originalName = (String) fieldOriginalNames.get(j);
                    if (originalName.equals(tableOriginalName + "_id")) {
                        bufferedWriter.write(
                                "    mainHtml += \"<div class='class-div-container-parent class-div-" + tableIntrospectedTableName + "'></div>\";\n");
                    }
                }
            }
            bufferedWriter.write("    $(\".class-div-main\").html(mainHtml);\n");
            bufferedWriter.write("    if(getInformationOf" + introspectedTable.getFullyQualifiedTable().getDomainObjectName() + "==1){\n");
            bufferedWriter.write(
                    "        getMainProcessWithClassNameAndList(SERVER_URL_CURRENT + \"/v1/common/" + tableOriginalNameReplaceWithSlash + "/get/without/sensitive/\"+getUrlSplit(\"" + MybatisUtilCommon.toLowerCaseAtFirstCharacter(introspectedTable.getFullyQualifiedTable().getDomainObjectName()) + "Id=\"), \".class-div-" + tableOriginalName + "\", \"single\",\"" + tableOriginalName + "\", \"" + MybatisUtilCommon.toLowerCaseAtFirstCharacter(introspectedTable.getFullyQualifiedTable().getDomainObjectName()) + "\",\"" + introspectedTable.getRemarks() + "\");\n" +
                            "    }\n");
            for (int i = 0; i < fileList.size(); i++) {
                Map fileMap = fileList.get(i);
                String tableIntrospectedTableName = (String) fileMap.get("tableIntrospectedTableName");
                String tableDomainObjectName = (String) fileMap.get("tableDomainObjectName");
                String tableRemarks = (String) fileMap.get("tableRemarks");
                String introspectedTableNameWithSlash = tableIntrospectedTableName.replaceAll("_", "/");
                List<Object> fieldOriginalNames = (List) fileMap.get("fieldOriginalNames");
                for (int j = 0; j < fieldOriginalNames.size(); j++) {
                    String fieldOriginalName = (String) fieldOriginalNames.get(j);
                    String fieldOriginalNameWithSlash = fieldOriginalName.replaceAll("_", "/");
                    if (fieldOriginalName.equals(tableOriginalName + "_id")) {
                        bufferedWriter.write("    if(getInformationOf" + tableDomainObjectName + "==1){\n" +
                                "        getMainProcessWithClassNameAndList(SERVER_URL_CURRENT + \"/v1/common/" + introspectedTableNameWithSlash + "/list/query/vo/" + fieldOriginalNameWithSlash + "?status=1&page=1&limit=\"+getMainProcessWithClassNameAndListLimitPreview+\"&" + MybatisUtilCommon.toLowerCaseAtFirstCharacter(introspectedTable.getFullyQualifiedTable().getDomainObjectName()) + "Id=\"+getUrlSplit(\"" + MybatisUtilCommon.toLowerCaseAtFirstCharacter(introspectedTable.getFullyQualifiedTable().getDomainObjectName()) + "Id=\"), \".class-div-" + tableIntrospectedTableName + "\", \"list\", \"" + tableIntrospectedTableName + "\", \"" + tableDomainObjectName + "\",\"" + tableRemarks + "\");\n" +
                                "    }\n");
                    }
                }
            }
            bufferedWriter.write(
                    "}\n" +
                            "\n" +
                            "/*%%%%%%%%%%%%%common ajax function start%%%%%%%%%%%%%*/\n" +
                            "\n" +
                            "var getMainProcessWithClassNameAndList = function (url, className, singleOrList,tableOriginalName, tableDomainObjectName, tableRemarks) {\n" +
                            "    $(className).prepend(loadingImage);\n" +
                            "    var token = getLocalStorageItem(\"token\");\n" +
                            "    if (token == undefined) {\n" +
                            "        gotoAuthUrl();\n" +
                            "    }\n" +
                            "    var resPast = getLocalStorageItem(getLocalStorageUrlKey(url));\n" +
                            "    if (resPast != undefined) {\n" +
                            "        try {\n" +
                            "            showHtml(JSON.parse(resPast), url, className, singleOrList,tableOriginalName, tableDomainObjectName, tableRemarks);\n" +
                            "        } catch (e) {\n" +
                            "            removeLocalStorageItem(getLocalStorageUrlKey(url));\n" +
                            "        }\n" +
                            "    }\n" +
                            "    $.ajax({\n" +
                            "        url: url,\n" +
                            "        type: \"get\",\n" +
                            "        cache: false,\n" +
                            "        async: true,\n" +
                            "        headers: {\"token\": token},\n" +
                            "        success: function (res) {\n" +
                            "            if (res.status == 200) {\n" +
                            "                setLocalStorageItem(getLocalStorageUrlKey(url), JSON.stringify(res));\n" +
                            "                showHtml(res, url, className, singleOrList,tableOriginalName, tableDomainObjectName, tableRemarks);\n" +
                            "            } else {\n" +
                            "                checkError(res);\n" +
                            "            }\n" +
                            "        },\n" +
                            "        error: function (message) {\n" +
                            "            showAlertFrame(ERROR_MESSAGE_CANNOT_CONNECT_TO_SERVER);\n" +
                            "        }\n" +
                            "    });\n" +
                            "}\n" +
                            "\n" +
                            "/*%%%%%%%%%%%%%common ajax function end%%%%%%%%%%%%%*/\n" +
                            "\n" +
                            "var showHtml = function (res, url, className, singleOrList,tableOriginalName, tableDomainObjectName, tableRemarks) {\n" +
                            "    var mainHtml = \"\";\n" +
                            "    mainHtml += \"<div class='class-div-items-\"+tableOriginalName+\"'>\";\n" +
                            "    var tableOriginalNameReplaceWithBar = tableOriginalName.replace(/_/g,'-');\n" +
                            "    var tableOriginalNames = tableOriginalName.split('_');\n" +
                            "    if(tableOriginalNames.length<2){" +
                            "        var tableOriginalNames = (tableOriginalName+'page').split('_');\n" +
                            "    }\n" +
                            "    if (res.data != undefined && res.data != null) {\n" +
                            "        if (singleOrList == \"single\") {\n" +
                            "            var item = res.data;\n" +
                            "            mainHtml += \"<div class='class-div-item-head class-div-item-head-\" + tableOriginalName + \"'><span class='class-span-item-head class-span-item-head-\" + tableOriginalName + \"'>\"+tableRemarks+\"资料</span>\" +\n" +
                            "                \"</div>\";\n");
            List<IntrospectedColumn> introspectedColumns = introspectedTable.getAllColumns();
            for (int i = 0; i < introspectedColumns.size(); i++) {
                IntrospectedColumn introspectedColumn = introspectedColumns.get(i);
                bufferedWriter.write("            mainHtml += \"<div class='class-div-single-item class-div-single-" + introspectedColumn.getActualColumnName() + " class-div-\" + tableOriginalName + \"-item class-div-\" + tableOriginalName + \"-item-\" + \"" + introspectedColumn.getActualColumnName() + "'><span class='class-span-item-label class-span-item-label-\" + tableOriginalName + \" class-span-item-label class-span-item-label-\" + tableOriginalName + \"-\" + \"" + introspectedColumn.getActualColumnName() + "\" + \"'>\"+(item." + introspectedColumn.getJavaProperty() + "+''==''?'':\"" + introspectedColumn.getRemarks().split(":")[0] + "：\")+\"</span><span class='class-span-\" + tableOriginalName + \"-item class-span-\" + tableOriginalName + \"-item-\" + \"" + introspectedColumn.getActualColumnName() + "'>\" ;\n");
                if (introspectedColumn.getActualColumnName().endsWith("_time") || introspectedColumn.getActualColumnName().endsWith("_date")) {
                    bufferedWriter.write(
                            "            mainHtml += timestampToTime(item." + introspectedColumn.getJavaProperty() + ") ; \n");
                } else if (introspectedColumn.getActualColumnName().endsWith("_image")) {
                    bufferedWriter.write(
                            "            mainHtml += (item." + introspectedColumn.getJavaProperty() + "==''?'':\"<image class='class-image  class-image-\" + tableOriginalName + \"-item-\" + \"" + introspectedColumn.getActualColumnName() + "' src='\"+item." + introspectedColumn.getJavaProperty() + "+\"'/>\") ; \n");
                } else if (introspectedColumn.getActualColumnName().endsWith("_video")) {
                    bufferedWriter.write(
                            "            mainHtml += (item." + introspectedColumn.getJavaProperty() + "==''?'':\"<video preload='none' muted='muted' controls='controls'  class='class-video-\" + tableOriginalName + \"-item-\" + \"" + introspectedColumn.getActualColumnName() + "' src='\"+item." + introspectedColumn.getJavaProperty() + "+\"'/>\") ; \n");
                } else {
                    if (introspectedColumn.getRemarks().contains(":")) {
                        writeValueWithSpanWithMainHtml(tableOriginalName, bufferedWriter, introspectedColumn);
                    } else {
                        bufferedWriter.write("            mainHtml +=  item." + introspectedColumn.getJavaProperty() + " ; \n");
                    }
                }
                bufferedWriter.write(
                        "            mainHtml += \"</span></div>\";\n");
            }
            bufferedWriter.write(
                    "         } else if (singleOrList == \"list\") {\n" +
                            "            var items = res.data;\n" +
                            "            mainHtml += \"<div class='class-div-container class-div-information-\" + tableOriginalName + \"'>\";\n" +
                            "            mainHtml += \"<div class='class-div-item-head class-div-item-head-\" + tableOriginalName + \"'>\"+\n" +
                            "                \"<span class='class-span-item-head class-span-item-head-\" + tableOriginalName + \"'>\"+tableRemarks+\"-列表</span>\" +\n" +
                            "                \"<span " + MybatisUtilCommon.toLowerCaseAtFirstCharacter(introspectedTable.getFullyQualifiedTable().getDomainObjectName()) + "Id=\"+getUrlSplit(\"" +
                            MybatisUtilCommon.toLowerCaseAtFirstCharacter(introspectedTable.getFullyQualifiedTable().getDomainObjectName()) + "Id=\")+\" class='class-span-item-head class-span-item-head-more class-span-item-head-\" + tableOriginalName + \"-more'>更多</span>\" +\n" +
                            "                \"</div>\";\n" +
                            "            if(items.length>0){\n" +
                            "                mainHtml += getPagerWithClassNameAndSingleOrList(res,url,className, singleOrList,tableOriginalName, tableDomainObjectName, tableRemarks);\n" +
                            "                mainHtml += \"<div class='class-table class-table-\" + tableOriginalName + \"'>\";\n" +
                            "                for (var k = 0; k < items.length; k++) {\n" +
                            "                    var item = items[k];\n" +
                            "                    mainHtml += \"<div class='class-div-item-information-show class-div-item-information-\" + tableOriginalName + \"' onclick=\\\"gotoUrl('../../../\"+tableOriginalNames[0]+\"/\"+tableOriginalNames[1]+\"/\"+tableOriginalNameReplaceWithBar+\"-preview/page.html?\"+toLowercaseAtFirstCharacter(tableDomainObjectName)+\"Id=\"+item.id+\"')\\\" >\";\n" +
                            "                    for(var i=0;i<tablesColumns.length;i++){" +
                            "                        var tablesColumn = tablesColumns[i];\n" +
                            "                        if(tablesColumn.tableIntrospectedTableName==tableOriginalName){\n" +
                            "                            for(var j=0;j<tablesColumn.fieldJavaProperties.length;j++){\n" +
                            "                                var fieldJavaProperty = tablesColumn.fieldJavaProperties[j];\n" +
                            "                                var fieldOriginalName = tablesColumn.fieldOriginalNames[j];\n" +
                            "                                var fieldOriginalNameSplits = fieldOriginalName.split('_');\n" +
                            "                                var fieldRemark = tablesColumn.fieldRemarks[j];\n" +
                            "                                var fieldRemarkOptions = tablesColumn.fieldRemarkOptions[j];\n" +
                            "                                var value=eval(\"item.\"+fieldJavaProperty);\n" +
                            "                                mainHtml += \"<div class='class-div-list-item class-div-list-split-has-\"+fieldOriginalNameSplits[fieldOriginalNameSplits.length-1]+\" class-div-list-\"+fieldOriginalName+\" class-div-item-\" + tableOriginalName + \" class-div-item-\" + tableOriginalName + \"-\" + fieldOriginalName +\"'><span class='class-span-item-label class-span-item-label-\" + tableOriginalName + \" class-span-item-label class-span-item-label-\" + tableOriginalName + \"-\" + fieldOriginalName + \"'>\"+(value+''==''?'':fieldRemark+\" : \")+\"</span><span class='class-span-item-\" + tableOriginalName + \" class-span-item-\" + tableOriginalName + \"-\" + fieldOriginalName+\"'>\";\n" +
                            "                                if(fieldOriginalName.substring(fieldOriginalName.length - 5)=='_time' || fieldOriginalName.substring(fieldOriginalName.length - 5)=='_date'){\n" +
                            "                                    mainHtml += timestampToTime(eval(\"item.\"+fieldJavaProperty)) ; \n" +
                            "                                } else if(fieldOriginalName.substring(fieldOriginalName.length - 6)=='_image'){\n" +
                            "                                    mainHtml += (value==''?'':\"<image src='\"+value+\"' class='class-image class-image-\" + tableOriginalName + \"-item-\" + fieldOriginalName + \"' />\"); \n" +
                            "                                } else if(fieldOriginalName.substring(fieldOriginalName.length - 6)=='_video'){\n" +
                            "                                    mainHtml += (value==''?'':\"<video  preload='none' muted='muted' controls='controls' src='\"+value+\"' class='class-video class-video-\" + tableOriginalName + \"-item-\" + fieldOriginalName + \"' />\") ; \n" +
                            "                                } else {\n" +
                            "                                    if(fieldRemarkOptions+''==''){\n" +
                            "                                        if(item.otherActualColumnName==undefined && item.otherJavaProperty==undefined){\n" +
                            "                                            mainHtml += value ; \n" +
                            "                                        }else{\n" +
                            "                                            if(item.otherJavaProperty==fieldJavaProperty){\n" +
                            "                                                mainHtml += eval(\"item.key.\"+fieldJavaProperty.replace('Id','')); \n" +
                            "                                            }else{\n" +
                            "                                                mainHtml += eval(\"item.item.\"+fieldJavaProperty); \n" +
                            "                                            }\n" +
                            "                                        }\n" +
                            "                                    }else{\n" +
                            "                                        var fieldRemarkOptionItems=fieldRemarkOptions.split(',');\n" +
                            "                                        for(var m=0;m<fieldRemarkOptionItems.length;m++){\n" +
                            "                                            var fieldRemarkOptionItem=fieldRemarkOptionItems[m].split(':');\n" +
                            "                                            if(fieldRemarkOptionItem[0]==value){\n" +
                            "                                                mainHtml += fieldRemarkOptionItem[1] ; \n" +
                            "                                            }\n" +
                            "                                        }\n" +
                            "                                    }\n" +
                            "                                }\n" +
                            "                                mainHtml += \"</span></div>\";\n" +
                            "                            }\n" +
                            "                        }\n" +
                            "                    }\n" +
                            "                    mainHtml += \"</div>\";\n" +
                            "                }\n" +
                            "                mainHtml += \"</div>\";\n" +
                            "            }\n" +
                            "            mainHtml += \"</div>\";\n" +
                            "        }\n" +
                            "    }\n" +
                            "    mainHtml += \"</div>\";\n" +
                            "    $(className).html(mainHtml);\n" +
                            "    $(\".class-span-item-head-\" + tableOriginalName + \"-more\").click(function () {\n" +
                            "        gotoUrl(\"../../../\"+tableOriginalNames[0]+\"/\"+tableOriginalNames[1]+\"/\"+tableOriginalNameReplaceWithBar+\"-list-preview/page.html?" + MybatisUtilCommon.toLowerCaseAtFirstCharacter(introspectedTable.getFullyQualifiedTable().getDomainObjectName()) + "Id=\"+$(this).attr('" + MybatisUtilCommon.toLowerCaseAtFirstCharacter(introspectedTable.getFullyQualifiedTable().getDomainObjectName()) + "Id'));\n" +
                            "    });\n" +
                            "}\n" +
                            "\n"
            );
            System.out.println("write to file success : " + file.getPath());
        } catch (IOException e) {
            e.printStackTrace();
        } finally {
            MybatisUtilCommon.closeBufferWriterAndFileOutputStream(outputStream, bufferedWriter);
        }
    }

    public static void writeTableJsUpdatePreviewPage(IntrospectedTable introspectedTable, String htmlPath, String modelUrl, String fileUploadServer, String serverUrl, String basePackage, String aspectPackage) {
        String tableOriginalName = introspectedTable.getFullyQualifiedTable().getIntrospectedTableName();
        String[] tableNames = tableOriginalName.split("_");
        if (tableNames.length < 2) {
            tableNames = (tableOriginalName + "_page").split("_");
        }
        String tableOriginalNameReplaceWithBar = tableOriginalName.replaceAll("_", "-");
        String tableOriginalNameReplaceWithSlash = tableOriginalName.replaceAll("_", "/");
        File file = null;
        OutputStream outputStream = null;
        BufferedWriter bufferedWriter = null;
        try {
            File folder = new File(htmlPath + "/" + tableNames[0] + "/" + tableNames[1] + "/" + tableOriginalNameReplaceWithBar + "-update-preview/js/");
            folder.mkdirs();
            String fileString = htmlPath + "/" + tableNames[0] + "/" + tableNames[1] + "/" + tableOriginalNameReplaceWithBar + "-update-preview/js/page.js";
            file = new File(fileString);
            file.createNewFile();
            outputStream = new FileOutputStream(file);
            bufferedWriter = new BufferedWriter(new OutputStreamWriter(outputStream, "utf-8"));
            bufferedWriter.write("$(function () {\n" +
                    "    writeBodyAndGetMainProcess();\n" +
                    "})\n" +
                    "\n" +
                    "var writeBodyAndGetMainProcess = function () {\n" +
                    "    var mainHtml = \"\";\n");
            bufferedWriter.write("    mainHtml += \"<div class='class-div-container-parent class-div-" + tableOriginalName + "'></div>\";\n");
            List<Map> fileList = MybatisUtilCommon.getFileListFromConfigFile();
            for (int i = 0; i < fileList.size(); i++) {
                Map fileMap = fileList.get(i);
                String tableIntrospectedTableName = (String) fileMap.get("tableIntrospectedTableName");
                String tableDomainObjectName = (String) fileMap.get("tableDomainObjectName");
                List<Object> fieldOriginalNames = (List) fileMap.get("fieldOriginalNames");
                for (int j = 0; j < fieldOriginalNames.size(); j++) {
                    String originalName = (String) fieldOriginalNames.get(j);
                    if (originalName.equals(tableOriginalName + "_id")) {
                        bufferedWriter.write("        mainHtml += \"<div class='class-div-container-parent class-div-" + tableIntrospectedTableName + "'></div>\";\n");
                    }
                }
            }
            bufferedWriter.write("    $(\".class-div-main\").html(mainHtml);\n");
            bufferedWriter.write("    if(getInformationOf" + introspectedTable.getFullyQualifiedTable().getDomainObjectName() + "==1){\n");
            bufferedWriter.write(
                    "        getMainProcessWithClassNameAndList(SERVER_URL_CURRENT + \"/v1/common/" + tableOriginalNameReplaceWithSlash + "/get/without/sensitive/\"+getUrlSplit(\"" +
                            MybatisUtilCommon.toLowerCaseAtFirstCharacter(introspectedTable.getFullyQualifiedTable().getDomainObjectName()) + "Id=\"), \".class-div-" + tableOriginalName + "\", \"single\",\"" + tableOriginalName + "\", \"" + MybatisUtilCommon.toLowerCaseAtFirstCharacter(introspectedTable.getFullyQualifiedTable().getDomainObjectName()) + "\",\"" + introspectedTable.getRemarks() + "\");\n" +
                            "    }\n");
            for (int i = 0; i < fileList.size(); i++) {
                Map fileMap = fileList.get(i);
                String tableIntrospectedTableName = (String) fileMap.get("tableIntrospectedTableName");
                String tableDomainObjectName = (String) fileMap.get("tableDomainObjectName");
                String tableRemarks = (String) fileMap.get("tableRemarks");
                String introspectedTableNameWithSlash = tableIntrospectedTableName.replaceAll("_", "/");
                List<Object> fieldOriginalNames = (List) fileMap.get("fieldOriginalNames");
                for (int j = 0; j < fieldOriginalNames.size(); j++) {
                    String fieldOriginalName = (String) fieldOriginalNames.get(j);
                    String fieldOriginalNameWithSlash = fieldOriginalName.replaceAll("_", "/");
                    if (fieldOriginalName.equals(tableOriginalName + "_id")) {
                        bufferedWriter.write("    if(getInformationOf" + tableDomainObjectName + "==1){\n" +
                                "        getMainProcessWithClassNameAndList(SERVER_URL_CURRENT + \"/v1/common/" + introspectedTableNameWithSlash + "/list/query/vo/" + fieldOriginalNameWithSlash + "?status=1&page=1&limit=\"+getMainProcessWithClassNameAndListLimitUpdatePreview+\"&" + MybatisUtilCommon.toLowerCaseAtFirstCharacter(introspectedTable.getFullyQualifiedTable().getDomainObjectName()) + "Id=\"+getUrlSplit(\"" + MybatisUtilCommon.toLowerCaseAtFirstCharacter(introspectedTable.getFullyQualifiedTable().getDomainObjectName()) + "Id=\"), \".class-div-" + tableIntrospectedTableName + "\", \"list\", \"" + tableIntrospectedTableName + "\", \"" + tableDomainObjectName + "\",\"" + tableRemarks + "\");\n" +
                                "    }\n");
                    }
                }
            }
            bufferedWriter.write(
                    "}\n" +
                            "\n" +
                            "/*%%%%%%%%%%%%%common ajax function start%%%%%%%%%%%%%*/\n" +
                            "\n" +
                            "var getMainProcessWithClassNameAndList = function (url, className, singleOrList,tableOriginalName, tableDomainObjectName, tableRemarks) {\n" +
//                            "    $(className).prepend(loadingImage);\n" +
                            "    var token = getLocalStorageItem(\"token\");\n" +
                            "    if (token == undefined) {\n" +
                            "        gotoAuthUrl();\n" +
                            "    }\n" +
                            "    var resPast = getLocalStorageItem(getLocalStorageUrlKey(url));\n" +
                            "    if (resPast != undefined) {\n" +
                            "        try {\n" +
                            "            showHtml(JSON.parse(resPast), url, className, singleOrList,tableOriginalName, tableDomainObjectName, tableRemarks);\n" +
                            "        } catch (e) {\n" +
                            "            removeLocalStorageItem(getLocalStorageUrlKey(url));\n" +
                            "        }\n" +
                            "    }\n" +
                            "    $.ajax({\n" +
                            "        url: url,\n" +
                            "        type: \"get\",\n" +
                            "        cache: false,\n" +
                            "        async: true,\n" +
                            "        headers: {\"token\": token},\n" +
                            "        success: function (res) {\n" +
                            "            if (res.status == 200) {\n" +
                            "                setLocalStorageItem(getLocalStorageUrlKey(url), JSON.stringify(res));\n" +
                            "                showHtml(res, url, className, singleOrList,tableOriginalName, tableDomainObjectName, tableRemarks);\n" +
                            "            } else {\n" +
                            "                checkError(res);\n" +
                            "            }\n" +
                            "        },\n" +
                            "        error: function (message) {\n" +
                            "            showAlertFrame(ERROR_MESSAGE_CANNOT_CONNECT_TO_SERVER);\n" +
                            "        }\n" +
                            "    });\n" +
                            "}\n" +
                            "\n" +
                            "/*%%%%%%%%%%%%%common ajax function end%%%%%%%%%%%%%*/\n" +
                            "\n" +
                            "var showHtml = function (res, url, className, singleOrList,tableOriginalName, tableDomainObjectName, tableRemarks) {\n" +
                            "    var mainHtml = \"\";\n" +
                            "    mainHtml += \"<div class='class-div-items-\"+tableOriginalName+\"'>\";\n" +
                            "    var tableOriginalNameReplaceWithBar = tableOriginalName.replace(/_/g,'-');\n" +
                            "    var tableOriginalNames = tableOriginalName.split('_');\n" +
                            "    if(tableOriginalNames.length<2){" +
                            "        var tableOriginalNames = (tableOriginalName+'_page').split('_');\n" +
                            "    }\n" +
                            "    if (res.data != undefined && res.data != null) {\n" +
                            "        if (singleOrList == \"single\") {\n" +
                            "            var item = res.data;\n" +
                            "            mainHtml += \"<div class='class-div-item-head class-div-item-head-\" + tableOriginalName + \"'><span class='class-span-item-head class-span-item-head-\" + tableOriginalName + \"'>\"+tableRemarks+\"资料</span>\" +\n" +
                            //增加一个更改按钮.
                            "            \"<span class='class-span-item-head-more class-span-update-this-item-\"+tableOriginalName+\"'>更改</span>\" + \n" +
                            "                \"</div>\";\n");
            List<IntrospectedColumn> introspectedColumns = introspectedTable.getAllColumns();
            for (int i = 0; i < introspectedColumns.size(); i++) {
                IntrospectedColumn introspectedColumn = introspectedColumns.get(i);
                bufferedWriter.write("            mainHtml += \"<div class='class-div-single-item class-div-single-" + introspectedColumn.getActualColumnName() + " class-div-\" + tableOriginalName + \"-item class-div-\" + tableOriginalName + \"-item-\" + \"" +
                        introspectedColumn.getActualColumnName() + "'><span class='class-span-item-label class-span-item-label-\" + tableOriginalName + \" class-span-item-label class-span-item-label-\" + tableOriginalName + \"-\" + \"" +
                        introspectedColumn.getActualColumnName() + "\" + \"'>\"+(item." + introspectedColumn.getJavaProperty() + "+''==''?'':\"" + introspectedColumn.getRemarks().split(":")[0] +
                        "：\")+\"</span><span class='class-span-\" + tableOriginalName + \"-item class-span-\" + tableOriginalName + \"-item-\" + \"" + introspectedColumn.getActualColumnName() + "'>\" ;\n");
                if (introspectedColumn.getActualColumnName().endsWith("_time") || introspectedColumn.getActualColumnName().endsWith("_date")) {
                    bufferedWriter.write(
                            "            mainHtml += timestampToTime(item." + introspectedColumn.getJavaProperty() + ") ; \n");
                } else if (introspectedColumn.getActualColumnName().endsWith("_image")) {
                    bufferedWriter.write(
                            "            mainHtml += (item." + introspectedColumn.getJavaProperty() + "==''?'':\"<image class='class-image  class-image-\" + tableOriginalName + \"-item-\" + \"" + introspectedColumn.getActualColumnName() + "' src='\"+item." + introspectedColumn.getJavaProperty() + "+\"'/>\") ; \n");
                } else if (introspectedColumn.getActualColumnName().endsWith("_video")) {
                    bufferedWriter.write(
                            "            mainHtml += (item." + introspectedColumn.getJavaProperty() + "==''?'':\"<video preload='none' muted='muted' controls='controls'  class='class-video-\" + tableOriginalName + \"-item-\" + \"" + introspectedColumn.getActualColumnName() + "' src='\"+item." + introspectedColumn.getJavaProperty() + "+\"'/>\") ; \n");
                } else {
                    if (introspectedColumn.getRemarks().contains(":")) {
                        writeValueWithSpanWithMainHtml(tableOriginalName, bufferedWriter, introspectedColumn);
                    } else {
                        bufferedWriter.write("            mainHtml +=  item." + introspectedColumn.getJavaProperty() + " ; \n");
                    }
                }
                bufferedWriter.write(
                        "            mainHtml += \"</span></div>\";\n");
            }
            bufferedWriter.write(
                    "         } else if (singleOrList == \"list\") {\n" +
                            "            var items = res.data;\n" +
                            "            mainHtml += \"<div class='class-div-container class-div-information-\" + tableOriginalName + \"'>\";\n" +
                            "            mainHtml += \"<div class='class-div-item-head class-div-item-head-\" + tableOriginalName + \"'>\"+\n" +
                            "                \"<span class='class-span-item-head class-span-item-head-\" + tableOriginalName + \"'>\"+tableRemarks+\"-列表</span>\" +\n" +
                            "                \"<span " + MybatisUtilCommon.toLowerCaseAtFirstCharacter(introspectedTable.getFullyQualifiedTable().getDomainObjectName()) + "Id=\"+getUrlSplit(\"" + MybatisUtilCommon.toLowerCaseAtFirstCharacter(introspectedTable.getFullyQualifiedTable().getDomainObjectName()) + "Id=\")+\" class='class-span-item-head class-span-item-head-more class-span-item-head-\" + tableOriginalName + \"-more'>更多</span>\" +\n" +
                            "                \"</div>\";\n" +
                            "            if(items.length>0){\n" +
                            "                mainHtml += getPagerWithClassNameAndSingleOrList(res,url,className, singleOrList,tableOriginalName, tableDomainObjectName, tableRemarks);\n" +
                            "                mainHtml += \"<div class='class-table class-table-\" + tableOriginalName + \"'>\";\n" +
                            "                for (var k = 0; k < items.length; k++) {\n" +
                            "                    var item = items[k];\n" +
                            "                    mainHtml += \"<div class='class-div-item-information-show class-div-item-information-\" + tableOriginalName + \"' onclick=\\\"gotoUrl('../../../\"+tableOriginalNames[0]+\"/\"+tableOriginalNames[1]+\"/\"+tableOriginalNameReplaceWithBar+\"-update-preview/page.html?\"+toLowercaseAtFirstCharacter(tableDomainObjectName)+\"Id=\"+item.id+\"')\\\" >\";\n" +
                            "                    for(var i=0;i<tablesColumns.length;i++){" +
                            "                        var tablesColumn = tablesColumns[i];\n" +
                            "                        if(tablesColumn.tableIntrospectedTableName==tableOriginalName){\n" +
                            "                            for(var j=0;j<tablesColumn.fieldJavaProperties.length;j++){\n" +
                            "                                var fieldJavaProperty = tablesColumn.fieldJavaProperties[j];\n" +
                            "                                var fieldOriginalName = tablesColumn.fieldOriginalNames[j];\n" +
                            "                                var fieldOriginalNameSplits = fieldOriginalName.split('_');\n" +
                            "                                var fieldRemark = tablesColumn.fieldRemarks[j];\n" +
                            "                                var fieldRemarkOptions = tablesColumn.fieldRemarkOptions[j];\n" +
                            "                                var value=eval(\"item.\"+fieldJavaProperty);\n" +
                            "                                mainHtml += \"<div class='class-div-list-item class-div-list-split-has-\"+fieldOriginalNameSplits[fieldOriginalNameSplits.length-1]+\" class-div-list-\"+fieldOriginalName+\" class-div-item-\" + tableOriginalName + \" class-div-item-\" + tableOriginalName + \"-\" + fieldOriginalName +\"'><span class='class-span-item-label class-span-item-label-\" + tableOriginalName + \" class-span-item-label class-span-item-label-\" + tableOriginalName + \"-\" + fieldOriginalName + \"'>\"+(value+''==''?'':fieldRemark+\" : \")+\"</span><span class='class-span-item-\" + tableOriginalName + \" class-span-item-\" + tableOriginalName + \"-\" + fieldOriginalName+\"'>\";\n" +
                            "                                if(fieldOriginalName.substring(fieldOriginalName.length - 5)=='_time' || fieldOriginalName.substring(fieldOriginalName.length - 5)=='_date'){\n" +
                            "                                    mainHtml += timestampToTime(eval(\"item.\"+fieldJavaProperty)) ; \n" +
                            "                                } else if(fieldOriginalName.substring(fieldOriginalName.length - 6)=='_image'){\n" +
                            "                                    mainHtml += (value==''?'':\"<image src='\"+value+\"' class='class-image class-image-\" + tableOriginalName + \"-item-\" + fieldOriginalName + \"' />\"); \n" +
                            "                                } else if(fieldOriginalName.substring(fieldOriginalName.length - 6)=='_video'){\n" +
                            "                                    mainHtml += (value==''?'':\"<video  preload='none' muted='muted' controls='controls' src='\"+value+\"' class='class-video class-video-\" + tableOriginalName + \"-item-\" + fieldOriginalName + \"' />\") ; \n" +
                            "                                } else {\n" +
                            "                                    if(fieldRemarkOptions+''==''){\n" +
                            "                                        if(item.otherActualColumnName==undefined && item.otherJavaProperty==undefined){\n" +
                            "                                            mainHtml += value ; \n" +
                            "                                        }else{\n" +
                            "                                            if(item.otherJavaProperty==fieldJavaProperty){\n" +
                            "                                                mainHtml += eval(\"item.key.\"+fieldJavaProperty.replace('Id','')); \n" +
                            "                                            }else{\n" +
                            "                                                mainHtml += eval(\"item.item.\"+fieldJavaProperty); \n" +
                            "                                            }\n" +
                            "                                        }\n" +
                            "                                    }else{\n" +
                            "                                        var fieldRemarkOptionItems=fieldRemarkOptions.split(',');\n" +
                            "                                        for(var m=0;m<fieldRemarkOptionItems.length;m++){\n" +
                            "                                            var fieldRemarkOptionItem=fieldRemarkOptionItems[m].split(':');\n" +
                            "                                            if(fieldRemarkOptionItem[0]==value){\n" +
                            "                                                mainHtml += fieldRemarkOptionItem[1] ; \n" +
                            "                                            }\n" +
                            "                                        }\n" +
                            "                                    }\n" +
                            "                                }\n" +
                            "                                mainHtml += \"</span></div>\";\n" +
                            "                            }\n" +
                            "                        }\n" +
                            "                    }\n" +
                            "                    mainHtml += \"</div>\";\n" +
                            "                }\n" +
                            "                mainHtml += \"</div>\";\n" +
                            "            }\n" +
                            "            mainHtml += \"</div>\";\n" +
                            "        }\n" +
                            "    }\n" +
                            "    mainHtml += \"</div>\";\n" +
                            "    $(className).html(mainHtml);\n" +
                            "    $(\".class-span-item-head-\" + tableOriginalName + \"-more\").click(function () {\n" +
                            "        gotoUrl(\"../../../\"+tableOriginalNames[0]+\"/\"+tableOriginalNames[1]+\"/\"+tableOriginalNameReplaceWithBar+\"-list/page.html?" + MybatisUtilCommon.toLowerCaseAtFirstCharacter(introspectedTable.getFullyQualifiedTable().getDomainObjectName()) + "Id=\"+$(this).attr('" + MybatisUtilCommon.toLowerCaseAtFirstCharacter(introspectedTable.getFullyQualifiedTable().getDomainObjectName()) + "Id'));\n" +
                            "    });\n" +
                            "    $(\".class-span-update-this-item-\"+tableOriginalName).click(function (){\n" +
                            "        gotoUrl(\"../../../\"+tableOriginalNames[0]+\"/\"+tableOriginalNames[1]+\"/\"+tableOriginalNameReplaceWithBar+\"-update/page.html?" + MybatisUtilCommon.toLowerCaseAtFirstCharacter(introspectedTable.getFullyQualifiedTable().getDomainObjectName()) + "Id=\"+getUrlSplit('" + MybatisUtilCommon.toLowerCaseAtFirstCharacter(introspectedTable.getFullyQualifiedTable().getDomainObjectName()) + "Id='));\n" +
                            "    }); \n" +
                            "}\n" +
                            "\n"
            );
            System.out.println("write to file success : " + file.getPath());
        } catch (IOException e) {
            e.printStackTrace();
        } finally {
            MybatisUtilCommon.closeBufferWriterAndFileOutputStream(outputStream, bufferedWriter);
        }
    }

}
